//===----------------------------------------------------------------------===//
//
// This source file is part of the Soto for AWS open source project
//
// Copyright (c) 2017-2021 the Soto project authors
// Licensed under Apache License v2.0
//
// See LICENSE.txt for license information
// See CONTRIBUTORS.txt for the list of Soto project authors
//
// SPDX-License-Identifier: Apache-2.0
//
//===----------------------------------------------------------------------===//

// THIS FILE IS AUTOMATICALLY GENERATED by https://github.com/soto-project/soto/tree/main/CodeGenerator. DO NOT EDIT.

import Foundation
import SotoCore

extension FSx {
    // MARK: Enums

    public enum AdministrativeActionType: String, CustomStringConvertible, Codable {
        case fileSystemAliasAssociation = "FILE_SYSTEM_ALIAS_ASSOCIATION"
        case fileSystemAliasDisassociation = "FILE_SYSTEM_ALIAS_DISASSOCIATION"
        case fileSystemUpdate = "FILE_SYSTEM_UPDATE"
        case storageOptimization = "STORAGE_OPTIMIZATION"
        public var description: String { return self.rawValue }
    }

    public enum AliasLifecycle: String, CustomStringConvertible, Codable {
        case available = "AVAILABLE"
        case createFailed = "CREATE_FAILED"
        case creating = "CREATING"
        case deleteFailed = "DELETE_FAILED"
        case deleting = "DELETING"
        public var description: String { return self.rawValue }
    }

    public enum AutoImportPolicyType: String, CustomStringConvertible, Codable {
        case new = "NEW"
        case newChanged = "NEW_CHANGED"
        case none = "NONE"
        public var description: String { return self.rawValue }
    }

    public enum BackupLifecycle: String, CustomStringConvertible, Codable {
        case available = "AVAILABLE"
        case creating = "CREATING"
        case deleted = "DELETED"
        case failed = "FAILED"
        case pending = "PENDING"
        case transferring = "TRANSFERRING"
        public var description: String { return self.rawValue }
    }

    public enum BackupType: String, CustomStringConvertible, Codable {
        case automatic = "AUTOMATIC"
        case awsBackup = "AWS_BACKUP"
        case userInitiated = "USER_INITIATED"
        public var description: String { return self.rawValue }
    }

    public enum DataRepositoryLifecycle: String, CustomStringConvertible, Codable {
        case available = "AVAILABLE"
        case creating = "CREATING"
        case deleting = "DELETING"
        case misconfigured = "MISCONFIGURED"
        case updating = "UPDATING"
        public var description: String { return self.rawValue }
    }

    public enum DataRepositoryTaskFilterName: String, CustomStringConvertible, Codable {
        case fileSystemId = "file-system-id"
        case taskLifecycle = "task-lifecycle"
        public var description: String { return self.rawValue }
    }

    public enum DataRepositoryTaskLifecycle: String, CustomStringConvertible, Codable {
        case canceled = "CANCELED"
        case canceling = "CANCELING"
        case executing = "EXECUTING"
        case failed = "FAILED"
        case pending = "PENDING"
        case succeeded = "SUCCEEDED"
        public var description: String { return self.rawValue }
    }

    public enum DataRepositoryTaskType: String, CustomStringConvertible, Codable {
        case exportToRepository = "EXPORT_TO_REPOSITORY"
        public var description: String { return self.rawValue }
    }

    public enum DriveCacheType: String, CustomStringConvertible, Codable {
        case none = "NONE"
        case read = "READ"
        public var description: String { return self.rawValue }
    }

    public enum FileSystemLifecycle: String, CustomStringConvertible, Codable {
        case available = "AVAILABLE"
        case creating = "CREATING"
        case deleting = "DELETING"
        case failed = "FAILED"
        case misconfigured = "MISCONFIGURED"
        case updating = "UPDATING"
        public var description: String { return self.rawValue }
    }

    public enum FileSystemMaintenanceOperation: String, CustomStringConvertible, Codable {
        case backingUp = "BACKING_UP"
        case patching = "PATCHING"
        public var description: String { return self.rawValue }
    }

    public enum FileSystemType: String, CustomStringConvertible, Codable {
        case lustre = "LUSTRE"
        case windows = "WINDOWS"
        public var description: String { return self.rawValue }
    }

    public enum FilterName: String, CustomStringConvertible, Codable {
        case backupType = "backup-type"
        case fileSystemId = "file-system-id"
        case fileSystemType = "file-system-type"
        public var description: String { return self.rawValue }
    }

    public enum LustreDeploymentType: String, CustomStringConvertible, Codable {
        case persistent1 = "PERSISTENT_1"
        case scratch1 = "SCRATCH_1"
        case scratch2 = "SCRATCH_2"
        public var description: String { return self.rawValue }
    }

    public enum ReportFormat: String, CustomStringConvertible, Codable {
        case reportCsv20191124 = "REPORT_CSV_20191124"
        public var description: String { return self.rawValue }
    }

    public enum ReportScope: String, CustomStringConvertible, Codable {
        case failedFilesOnly = "FAILED_FILES_ONLY"
        public var description: String { return self.rawValue }
    }

    public enum Status: String, CustomStringConvertible, Codable {
        case completed = "COMPLETED"
        case failed = "FAILED"
        case inProgress = "IN_PROGRESS"
        case pending = "PENDING"
        case updatedOptimizing = "UPDATED_OPTIMIZING"
        public var description: String { return self.rawValue }
    }

    public enum StorageType: String, CustomStringConvertible, Codable {
        case hdd = "HDD"
        case ssd = "SSD"
        public var description: String { return self.rawValue }
    }

    public enum WindowsDeploymentType: String, CustomStringConvertible, Codable {
        case multiAz1 = "MULTI_AZ_1"
        case singleAz1 = "SINGLE_AZ_1"
        case singleAz2 = "SINGLE_AZ_2"
        public var description: String { return self.rawValue }
    }

    // MARK: Shapes

    public struct ActiveDirectoryBackupAttributes: AWSDecodableShape {
        /// The ID of the AWS Managed Microsoft Active Directory instance to which the file system is joined.
        public let activeDirectoryId: String?
        /// The fully qualified domain name of the self-managed AD directory.
        public let domainName: String?

        public init(activeDirectoryId: String? = nil, domainName: String? = nil) {
            self.activeDirectoryId = activeDirectoryId
            self.domainName = domainName
        }

        private enum CodingKeys: String, CodingKey {
            case activeDirectoryId = "ActiveDirectoryId"
            case domainName = "DomainName"
        }
    }

    public struct AdministrativeAction: AWSDecodableShape {
        public let administrativeActionType: AdministrativeActionType?
        public let failureDetails: AdministrativeActionFailureDetails?
        /// Provides the percent complete of a STORAGE_OPTIMIZATION administrative action. Does not apply to any other administrative action type.
        public let progressPercent: Int?
        /// Time that the administrative action request was received.
        public let requestTime: Date?
        /// Describes the status of the administrative action, as follows:    FAILED - Amazon FSx failed to process the administrative action successfully.    IN_PROGRESS - Amazon FSx is processing the administrative action.    PENDING - Amazon FSx is waiting to process the administrative action.    COMPLETED - Amazon FSx has finished processing the administrative task.    UPDATED_OPTIMIZING - For a storage capacity increase update, Amazon FSx has updated the file system with the new storage capacity, and is now performing the storage optimization process. For more information, see Managing storage capacity in the Amazon FSx for Windows File Server User Guide and Managing storage and throughput capacity in the Amazon FSx for Lustre User Guide.
        public let status: Status?
        /// Describes the target value for the administration action, provided in the UpdateFileSystem operation. Returned for FILE_SYSTEM_UPDATE administrative actions.
        public let targetFileSystemValues: FileSystem?

        public init(administrativeActionType: AdministrativeActionType? = nil, failureDetails: AdministrativeActionFailureDetails? = nil, progressPercent: Int? = nil, requestTime: Date? = nil, status: Status? = nil, targetFileSystemValues: FileSystem? = nil) {
            self.administrativeActionType = administrativeActionType
            self.failureDetails = failureDetails
            self.progressPercent = progressPercent
            self.requestTime = requestTime
            self.status = status
            self.targetFileSystemValues = targetFileSystemValues
        }

        private enum CodingKeys: String, CodingKey {
            case administrativeActionType = "AdministrativeActionType"
            case failureDetails = "FailureDetails"
            case progressPercent = "ProgressPercent"
            case requestTime = "RequestTime"
            case status = "Status"
            case targetFileSystemValues = "TargetFileSystemValues"
        }
    }

    public struct AdministrativeActionFailureDetails: AWSDecodableShape {
        /// Error message providing details about the failed administrative action.
        public let message: String?

        public init(message: String? = nil) {
            self.message = message
        }

        private enum CodingKeys: String, CodingKey {
            case message = "Message"
        }
    }

    public struct Alias: AWSDecodableShape {
        /// Describes the state of the DNS alias.   AVAILABLE - The DNS alias is associated with an Amazon FSx file system.   CREATING - Amazon FSx is creating the DNS alias and associating it with the file system.   CREATE_FAILED - Amazon FSx was unable to associate the DNS alias with the file system.   DELETING - Amazon FSx is disassociating the DNS alias from the file system and deleting it.   DELETE_FAILED - Amazon FSx was unable to disassocate the DNS alias from the file system.
        public let lifecycle: AliasLifecycle?
        /// The name of the DNS alias. The alias name has to meet the following requirements:   Formatted as a fully-qualified domain name (FQDN), hostname.domain, for example, accounting.example.com.   Can contain alphanumeric characters and the hyphen (-).   Cannot start or end with a hyphen.   Can start with a numeric.   For DNS names, Amazon FSx stores alphabetic characters as lowercase letters (a-z), regardless of how you specify them: as uppercase letters, lowercase letters, or the corresponding letters in escape codes.
        public let name: String?

        public init(lifecycle: AliasLifecycle? = nil, name: String? = nil) {
            self.lifecycle = lifecycle
            self.name = name
        }

        private enum CodingKeys: String, CodingKey {
            case lifecycle = "Lifecycle"
            case name = "Name"
        }
    }

    public struct AssociateFileSystemAliasesRequest: AWSEncodableShape {
        /// An array of one or more DNS alias names to associate with the file system. The alias name has to comply with the following formatting requirements:   Formatted as a fully-qualified domain name (FQDN),  hostname.domain , for example, accounting.corp.example.com.   Can contain alphanumeric characters and the hyphen (-).   Cannot start or end with a hyphen.   Can start with a numeric.   For DNS alias names, Amazon FSx stores alphabetic characters as lowercase letters (a-z), regardless of how you specify them: as uppercase letters, lowercase letters, or the corresponding letters in escape codes.
        public let aliases: [String]
        public let clientRequestToken: String?
        /// Specifies the file system with which you want to associate one or more DNS aliases.
        public let fileSystemId: String

        public init(aliases: [String], clientRequestToken: String? = AssociateFileSystemAliasesRequest.idempotencyToken(), fileSystemId: String) {
            self.aliases = aliases
            self.clientRequestToken = clientRequestToken
            self.fileSystemId = fileSystemId
        }

        public func validate(name: String) throws {
            try self.aliases.forEach {
                try validate($0, name: "aliases[]", parent: name, max: 253)
                try validate($0, name: "aliases[]", parent: name, min: 4)
                try validate($0, name: "aliases[]", parent: name, pattern: "^[^\\u0000\\u0085\\u2028\\u2029\\r\\n]{4,253}$")
            }
            try self.validate(self.aliases, name: "aliases", parent: name, max: 50)
            try self.validate(self.clientRequestToken, name: "clientRequestToken", parent: name, max: 63)
            try self.validate(self.clientRequestToken, name: "clientRequestToken", parent: name, min: 1)
            try self.validate(self.clientRequestToken, name: "clientRequestToken", parent: name, pattern: "[A-za-z0-9_.-]{0,63}$")
            try self.validate(self.fileSystemId, name: "fileSystemId", parent: name, max: 21)
            try self.validate(self.fileSystemId, name: "fileSystemId", parent: name, min: 11)
            try self.validate(self.fileSystemId, name: "fileSystemId", parent: name, pattern: "^(fs-[0-9a-f]{8,})$")
        }

        private enum CodingKeys: String, CodingKey {
            case aliases = "Aliases"
            case clientRequestToken = "ClientRequestToken"
            case fileSystemId = "FileSystemId"
        }
    }

    public struct AssociateFileSystemAliasesResponse: AWSDecodableShape {
        /// An array of the DNS aliases that Amazon FSx is associating with the file system.
        public let aliases: [Alias]?

        public init(aliases: [Alias]? = nil) {
            self.aliases = aliases
        }

        private enum CodingKeys: String, CodingKey {
            case aliases = "Aliases"
        }
    }

    public struct Backup: AWSDecodableShape {
        /// The ID of the backup.
        public let backupId: String
        /// The time when a particular backup was created.
        public let creationTime: Date
        /// The configuration of the self-managed Microsoft Active Directory (AD) to which the Windows File Server instance is joined.
        public let directoryInformation: ActiveDirectoryBackupAttributes?
        /// Details explaining any failures that occur when creating a backup.
        public let failureDetails: BackupFailureDetails?
        /// Metadata of the file system associated with the backup. This metadata is persisted even if the file system is deleted.
        public let fileSystem: FileSystem
        /// The ID of the AWS Key Management Service (AWS KMS) key used to encrypt the backup of the Amazon FSx file system's data at rest.
        public let kmsKeyId: String?
        /// The lifecycle status of the backup.    AVAILABLE - The backup is fully available.    PENDING - For user-initiated backups on Lustre file systems only; Amazon FSx has not started creating the backup.    CREATING - Amazon FSx is creating the backup.    TRANSFERRING - For user-initiated backups on Lustre file systems only; Amazon FSx is transferring the backup to S3.    DELETED - Amazon FSx deleted the backup and it is no longer available.    FAILED - Amazon FSx could not complete the backup.
        public let lifecycle: BackupLifecycle
        public let progressPercent: Int?
        /// The Amazon Resource Name (ARN) for the backup resource.
        public let resourceARN: String?
        /// Tags associated with a particular file system.
        public let tags: [Tag]?
        /// The type of the file system backup.
        public let type: BackupType

        public init(backupId: String, creationTime: Date, directoryInformation: ActiveDirectoryBackupAttributes? = nil, failureDetails: BackupFailureDetails? = nil, fileSystem: FileSystem, kmsKeyId: String? = nil, lifecycle: BackupLifecycle, progressPercent: Int? = nil, resourceARN: String? = nil, tags: [Tag]? = nil, type: BackupType) {
            self.backupId = backupId
            self.creationTime = creationTime
            self.directoryInformation = directoryInformation
            self.failureDetails = failureDetails
            self.fileSystem = fileSystem
            self.kmsKeyId = kmsKeyId
            self.lifecycle = lifecycle
            self.progressPercent = progressPercent
            self.resourceARN = resourceARN
            self.tags = tags
            self.type = type
        }

        private enum CodingKeys: String, CodingKey {
            case backupId = "BackupId"
            case creationTime = "CreationTime"
            case directoryInformation = "DirectoryInformation"
            case failureDetails = "FailureDetails"
            case fileSystem = "FileSystem"
            case kmsKeyId = "KmsKeyId"
            case lifecycle = "Lifecycle"
            case progressPercent = "ProgressPercent"
            case resourceARN = "ResourceARN"
            case tags = "Tags"
            case type = "Type"
        }
    }

    public struct BackupFailureDetails: AWSDecodableShape {
        /// A message describing the backup creation failure.
        public let message: String?

        public init(message: String? = nil) {
            self.message = message
        }

        private enum CodingKeys: String, CodingKey {
            case message = "Message"
        }
    }

    public struct CancelDataRepositoryTaskRequest: AWSEncodableShape {
        /// Specifies the data repository task to cancel.
        public let taskId: String

        public init(taskId: String) {
            self.taskId = taskId
        }

        public func validate(name: String) throws {
            try self.validate(self.taskId, name: "taskId", parent: name, max: 128)
            try self.validate(self.taskId, name: "taskId", parent: name, min: 12)
            try self.validate(self.taskId, name: "taskId", parent: name, pattern: "^(task-[0-9a-f]{17,})$")
        }

        private enum CodingKeys: String, CodingKey {
            case taskId = "TaskId"
        }
    }

    public struct CancelDataRepositoryTaskResponse: AWSDecodableShape {
        /// The lifecycle status of the data repository task, as follows:    PENDING - Amazon FSx has not started the task.    EXECUTING - Amazon FSx is processing the task.    FAILED - Amazon FSx was not able to complete the task. For example, there may be files the task failed to process. The DataRepositoryTaskFailureDetails property provides more information about task failures.    SUCCEEDED - FSx completed the task successfully.    CANCELED - Amazon FSx canceled the task and it did not complete.    CANCELING - FSx is in process of canceling the task.
        public let lifecycle: DataRepositoryTaskLifecycle?
        /// The ID of the task being canceled.
        public let taskId: String?

        public init(lifecycle: DataRepositoryTaskLifecycle? = nil, taskId: String? = nil) {
            self.lifecycle = lifecycle
            self.taskId = taskId
        }

        private enum CodingKeys: String, CodingKey {
            case lifecycle = "Lifecycle"
            case taskId = "TaskId"
        }
    }

    public struct CompletionReport: AWSEncodableShape & AWSDecodableShape {
        /// Set Enabled to True to generate a CompletionReport when the task completes. If set to true, then you need to provide a report Scope, Path, and Format. Set Enabled to False if you do not want a CompletionReport generated when the task completes.
        public let enabled: Bool
        /// Required if Enabled is set to true. Specifies the format of the CompletionReport. REPORT_CSV_20191124 is the only format currently supported. When Format is set to REPORT_CSV_20191124, the CompletionReport is provided in CSV format, and is delivered to {path}/task-{id}/failures.csv.
        public let format: ReportFormat?
        /// Required if Enabled is set to true. Specifies the location of the report on the file system's linked S3 data repository. An absolute path that defines where the completion report will be stored in the destination location. The Path you provide must be located within the file system’s ExportPath. An example Path value is "s3://myBucket/myExportPath/optionalPrefix". The report provides the following information for each file in the report: FilePath, FileStatus, and ErrorCode. To learn more about a file system's ExportPath, see .
        public let path: String?
        /// Required if Enabled is set to true. Specifies the scope of the CompletionReport; FAILED_FILES_ONLY is the only scope currently supported. When Scope is set to FAILED_FILES_ONLY, the CompletionReport only contains information about files that the data repository task failed to process.
        public let scope: ReportScope?

        public init(enabled: Bool, format: ReportFormat? = nil, path: String? = nil, scope: ReportScope? = nil) {
            self.enabled = enabled
            self.format = format
            self.path = path
            self.scope = scope
        }

        public func validate(name: String) throws {
            try self.validate(self.path, name: "path", parent: name, max: 4357)
            try self.validate(self.path, name: "path", parent: name, min: 3)
            try self.validate(self.path, name: "path", parent: name, pattern: "^[^\\u0000\\u0085\\u2028\\u2029\\r\\n]{3,4357}$")
        }

        private enum CodingKeys: String, CodingKey {
            case enabled = "Enabled"
            case format = "Format"
            case path = "Path"
            case scope = "Scope"
        }
    }

    public struct CreateBackupRequest: AWSEncodableShape {
        /// (Optional) A string of up to 64 ASCII characters that Amazon FSx uses to ensure idempotent creation. This string is automatically filled on your behalf when you use the AWS Command Line Interface (AWS CLI) or an AWS SDK.
        public let clientRequestToken: String?
        /// The ID of the file system to back up.
        public let fileSystemId: String
        /// (Optional) The tags to apply to the backup at backup creation. The key value of the Name tag appears in the console as the backup name. If you have set CopyTagsToBackups to true, and you specify one or more tags using the CreateBackup action, no existing file system tags are copied from the file system to the backup.
        public let tags: [Tag]?

        public init(clientRequestToken: String? = CreateBackupRequest.idempotencyToken(), fileSystemId: String, tags: [Tag]? = nil) {
            self.clientRequestToken = clientRequestToken
            self.fileSystemId = fileSystemId
            self.tags = tags
        }

        public func validate(name: String) throws {
            try self.validate(self.clientRequestToken, name: "clientRequestToken", parent: name, max: 63)
            try self.validate(self.clientRequestToken, name: "clientRequestToken", parent: name, min: 1)
            try self.validate(self.clientRequestToken, name: "clientRequestToken", parent: name, pattern: "[A-za-z0-9_.-]{0,63}$")
            try self.validate(self.fileSystemId, name: "fileSystemId", parent: name, max: 21)
            try self.validate(self.fileSystemId, name: "fileSystemId", parent: name, min: 11)
            try self.validate(self.fileSystemId, name: "fileSystemId", parent: name, pattern: "^(fs-[0-9a-f]{8,})$")
            try self.tags?.forEach {
                try $0.validate(name: "\(name).tags[]")
            }
            try self.validate(self.tags, name: "tags", parent: name, max: 50)
            try self.validate(self.tags, name: "tags", parent: name, min: 1)
        }

        private enum CodingKeys: String, CodingKey {
            case clientRequestToken = "ClientRequestToken"
            case fileSystemId = "FileSystemId"
            case tags = "Tags"
        }
    }

    public struct CreateBackupResponse: AWSDecodableShape {
        /// A description of the backup.
        public let backup: Backup?

        public init(backup: Backup? = nil) {
            self.backup = backup
        }

        private enum CodingKeys: String, CodingKey {
            case backup = "Backup"
        }
    }

    public struct CreateDataRepositoryTaskRequest: AWSEncodableShape {
        public let clientRequestToken: String?
        public let fileSystemId: String
        /// (Optional) The path or paths on the Amazon FSx file system to use when the data repository task is processed. The default path is the file system root directory. The paths you provide need to be relative to the mount point of the file system. If the mount point is /mnt/fsx and /mnt/fsx/path1 is a directory or file on the file system you want to export, then the path to provide is path1. If a path that you provide isn't valid, the task fails.
        public let paths: [String]?
        /// Defines whether or not Amazon FSx provides a CompletionReport once the task has completed. A CompletionReport provides a detailed report on the files that Amazon FSx processed that meet the criteria specified by the Scope parameter. For more information, see Working with Task Completion Reports.
        public let report: CompletionReport
        public let tags: [Tag]?
        /// Specifies the type of data repository task to create.
        public let type: DataRepositoryTaskType

        public init(clientRequestToken: String? = CreateDataRepositoryTaskRequest.idempotencyToken(), fileSystemId: String, paths: [String]? = nil, report: CompletionReport, tags: [Tag]? = nil, type: DataRepositoryTaskType) {
            self.clientRequestToken = clientRequestToken
            self.fileSystemId = fileSystemId
            self.paths = paths
            self.report = report
            self.tags = tags
            self.type = type
        }

        public func validate(name: String) throws {
            try self.validate(self.clientRequestToken, name: "clientRequestToken", parent: name, max: 63)
            try self.validate(self.clientRequestToken, name: "clientRequestToken", parent: name, min: 1)
            try self.validate(self.clientRequestToken, name: "clientRequestToken", parent: name, pattern: "[A-za-z0-9_.-]{0,63}$")
            try self.validate(self.fileSystemId, name: "fileSystemId", parent: name, max: 21)
            try self.validate(self.fileSystemId, name: "fileSystemId", parent: name, min: 11)
            try self.validate(self.fileSystemId, name: "fileSystemId", parent: name, pattern: "^(fs-[0-9a-f]{8,})$")
            try self.paths?.forEach {
                try validate($0, name: "paths[]", parent: name, max: 4096)
                try validate($0, name: "paths[]", parent: name, min: 0)
                try validate($0, name: "paths[]", parent: name, pattern: "^[^\\u0000\\u0085\\u2028\\u2029\\r\\n]{0,4096}$")
            }
            try self.validate(self.paths, name: "paths", parent: name, max: 100)
            try self.report.validate(name: "\(name).report")
            try self.tags?.forEach {
                try $0.validate(name: "\(name).tags[]")
            }
            try self.validate(self.tags, name: "tags", parent: name, max: 50)
            try self.validate(self.tags, name: "tags", parent: name, min: 1)
        }

        private enum CodingKeys: String, CodingKey {
            case clientRequestToken = "ClientRequestToken"
            case fileSystemId = "FileSystemId"
            case paths = "Paths"
            case report = "Report"
            case tags = "Tags"
            case type = "Type"
        }
    }

    public struct CreateDataRepositoryTaskResponse: AWSDecodableShape {
        /// The description of the data repository task that you just created.
        public let dataRepositoryTask: DataRepositoryTask?

        public init(dataRepositoryTask: DataRepositoryTask? = nil) {
            self.dataRepositoryTask = dataRepositoryTask
        }

        private enum CodingKeys: String, CodingKey {
            case dataRepositoryTask = "DataRepositoryTask"
        }
    }

    public struct CreateFileSystemFromBackupRequest: AWSEncodableShape {
        public let backupId: String
        /// A string of up to 64 ASCII characters that Amazon FSx uses to ensure idempotent creation. This string is automatically filled on your behalf when you use the AWS Command Line Interface (AWS CLI) or an AWS SDK.
        public let clientRequestToken: String?
        public let lustreConfiguration: CreateFileSystemLustreConfiguration?
        /// A list of IDs for the security groups that apply to the specified network interfaces created for file system access. These security groups apply to all network interfaces. This value isn't returned in later DescribeFileSystem requests.
        public let securityGroupIds: [String]?
        /// Sets the storage type for the Windows file system you're creating from a backup. Valid values are SSD and HDD.   Set to SSD to use solid state drive storage. Supported on all Windows deployment types.   Set to HDD to use hard disk drive storage. Supported on SINGLE_AZ_2 and MULTI_AZ_1 Windows file system deployment types.     Default value is SSD.   HDD and SSD storage types have different minimum storage capacity requirements. A restored file system's storage capacity is tied to the file system that was backed up. You can create a file system that uses HDD storage from a backup of a file system that used SSD storage only if the original SSD file system had a storage capacity of at least 2000 GiB.
        public let storageType: StorageType?
        /// Specifies the IDs of the subnets that the file system will be accessible from. For Windows MULTI_AZ_1 file system deployment types, provide exactly two subnet IDs, one for the preferred file server and one for the standby file server. You specify one of these subnets as the preferred subnet using the WindowsConfiguration &gt; PreferredSubnetID property. For Windows SINGLE_AZ_1 and SINGLE_AZ_2 deployment types and Lustre file systems, provide exactly one subnet ID. The file server is launched in that subnet's Availability Zone.
        public let subnetIds: [String]
        /// The tags to be applied to the file system at file system creation. The key value of the Name tag appears in the console as the file system name.
        public let tags: [Tag]?
        /// The configuration for this Microsoft Windows file system.
        public let windowsConfiguration: CreateFileSystemWindowsConfiguration?

        public init(backupId: String, clientRequestToken: String? = CreateFileSystemFromBackupRequest.idempotencyToken(), lustreConfiguration: CreateFileSystemLustreConfiguration? = nil, securityGroupIds: [String]? = nil, storageType: StorageType? = nil, subnetIds: [String], tags: [Tag]? = nil, windowsConfiguration: CreateFileSystemWindowsConfiguration? = nil) {
            self.backupId = backupId
            self.clientRequestToken = clientRequestToken
            self.lustreConfiguration = lustreConfiguration
            self.securityGroupIds = securityGroupIds
            self.storageType = storageType
            self.subnetIds = subnetIds
            self.tags = tags
            self.windowsConfiguration = windowsConfiguration
        }

        public func validate(name: String) throws {
            try self.validate(self.backupId, name: "backupId", parent: name, max: 128)
            try self.validate(self.backupId, name: "backupId", parent: name, min: 12)
            try self.validate(self.backupId, name: "backupId", parent: name, pattern: "^(backup-[0-9a-f]{8,})$")
            try self.validate(self.clientRequestToken, name: "clientRequestToken", parent: name, max: 63)
            try self.validate(self.clientRequestToken, name: "clientRequestToken", parent: name, min: 1)
            try self.validate(self.clientRequestToken, name: "clientRequestToken", parent: name, pattern: "[A-za-z0-9_.-]{0,63}$")
            try self.lustreConfiguration?.validate(name: "\(name).lustreConfiguration")
            try self.securityGroupIds?.forEach {
                try validate($0, name: "securityGroupIds[]", parent: name, max: 20)
                try validate($0, name: "securityGroupIds[]", parent: name, min: 11)
                try validate($0, name: "securityGroupIds[]", parent: name, pattern: "^(sg-[0-9a-f]{8,})$")
            }
            try self.validate(self.securityGroupIds, name: "securityGroupIds", parent: name, max: 50)
            try self.subnetIds.forEach {
                try validate($0, name: "subnetIds[]", parent: name, max: 24)
                try validate($0, name: "subnetIds[]", parent: name, min: 15)
                try validate($0, name: "subnetIds[]", parent: name, pattern: "^(subnet-[0-9a-f]{8,})$")
            }
            try self.validate(self.subnetIds, name: "subnetIds", parent: name, max: 50)
            try self.tags?.forEach {
                try $0.validate(name: "\(name).tags[]")
            }
            try self.validate(self.tags, name: "tags", parent: name, max: 50)
            try self.validate(self.tags, name: "tags", parent: name, min: 1)
            try self.windowsConfiguration?.validate(name: "\(name).windowsConfiguration")
        }

        private enum CodingKeys: String, CodingKey {
            case backupId = "BackupId"
            case clientRequestToken = "ClientRequestToken"
            case lustreConfiguration = "LustreConfiguration"
            case securityGroupIds = "SecurityGroupIds"
            case storageType = "StorageType"
            case subnetIds = "SubnetIds"
            case tags = "Tags"
            case windowsConfiguration = "WindowsConfiguration"
        }
    }

    public struct CreateFileSystemFromBackupResponse: AWSDecodableShape {
        /// A description of the file system.
        public let fileSystem: FileSystem?

        public init(fileSystem: FileSystem? = nil) {
            self.fileSystem = fileSystem
        }

        private enum CodingKeys: String, CodingKey {
            case fileSystem = "FileSystem"
        }
    }

    public struct CreateFileSystemLustreConfiguration: AWSEncodableShape {
        ///  (Optional) When you create your file system, your existing S3 objects appear as file and directory listings. Use this property to choose how Amazon FSx keeps your file and directory listings up to date as you add or modify objects in your linked S3 bucket. AutoImportPolicy can have the following values:    NONE - (Default) AutoImport is off. Amazon FSx only updates file and directory listings from the linked S3 bucket when the file system is created. FSx does not update file and directory listings for any new or changed objects after choosing this option.    NEW - AutoImport is on. Amazon FSx automatically imports directory listings of any new objects added to the linked S3 bucket that do not currently exist in the FSx file system.     NEW_CHANGED - AutoImport is on. Amazon FSx automatically imports file and directory listings of any new objects added to the S3 bucket and any existing objects that are changed in the S3 bucket after you choose this option.    For more information, see Automatically import updates from your S3 bucket.
        public let autoImportPolicy: AutoImportPolicyType?
        public let automaticBackupRetentionDays: Int?
        /// (Optional) Not available to use with file systems that are linked to a data repository. A boolean flag indicating whether tags for the file system should be copied to backups. The default value is false. If it's set to true, all file system tags are copied to all automatic and user-initiated backups when the user doesn't specify any backup-specific tags. If this value is true, and you specify one or more backup tags, only the specified tags are copied to backups. If you specify one or more tags when creating a user-initiated backup, no tags are copied from the file system, regardless of this value. For more information, see Working with backups.
        public let copyTagsToBackups: Bool?
        public let dailyAutomaticBackupStartTime: String?
        ///  Choose SCRATCH_1 and SCRATCH_2 deployment types when you need temporary storage and shorter-term processing of data. The SCRATCH_2 deployment type provides in-transit encryption of data and higher burst throughput capacity than SCRATCH_1. Choose PERSISTENT_1 deployment type for longer-term storage and workloads and encryption of data in transit. To learn more about deployment types, see  FSx for Lustre Deployment Options. Encryption of data in-transit is automatically enabled when you access a SCRATCH_2 or PERSISTENT_1 file system from Amazon EC2 instances that support this feature. (Default = SCRATCH_1)  Encryption of data in-transit for SCRATCH_2 and PERSISTENT_1 deployment types is supported when accessed from supported instance types in supported AWS Regions. To learn more, Encrypting Data in Transit.
        public let deploymentType: LustreDeploymentType?
        /// The type of drive cache used by PERSISTENT_1 file systems that are provisioned with HDD storage devices. This parameter is required when storage type is HDD. Set to READ, improve the performance for frequently accessed files and allows 20% of the total storage capacity of the file system to be cached.  This parameter is required when StorageType is set to HDD.
        public let driveCacheType: DriveCacheType?
        /// (Optional) The path in Amazon S3 where the root of your Amazon FSx file system is exported. The path must use the same Amazon S3 bucket as specified in ImportPath. You can provide an optional prefix to which new and changed data is to be exported from your Amazon FSx for Lustre file system. If an ExportPath value is not provided, Amazon FSx sets a default export path, s3://import-bucket/FSxLustre[creation-timestamp]. The timestamp is in UTC format, for example s3://import-bucket/FSxLustre20181105T222312Z. The Amazon S3 export bucket must be the same as the import bucket specified by ImportPath. If you only specify a bucket name, such as s3://import-bucket, you get a 1:1 mapping of file system objects to S3 bucket objects. This mapping means that the input data in S3 is overwritten on export. If you provide a custom prefix in the export path, such as s3://import-bucket/[custom-optional-prefix], Amazon FSx exports the contents of your file system to that export prefix in the Amazon S3 bucket.
        public let exportPath: String?
        /// (Optional) For files imported from a data repository, this value determines the stripe count and maximum amount of data per file (in MiB) stored on a single physical disk. The maximum number of disks that a single file can be striped across is limited by the total number of disks that make up the file system. The default chunk size is 1,024 MiB (1 GiB) and can go as high as 512,000 MiB (500 GiB). Amazon S3 objects have a maximum size of 5 TB.
        public let importedFileChunkSize: Int?
        /// (Optional) The path to the Amazon S3 bucket (including the optional prefix) that you're using as the data repository for your Amazon FSx for Lustre file system. The root of your FSx for Lustre file system will be mapped to the root of the Amazon S3 bucket you select. An example is s3://import-bucket/optional-prefix. If you specify a prefix after the Amazon S3 bucket name, only object keys with that prefix are loaded into the file system.
        public let importPath: String?
        ///  Required for the PERSISTENT_1 deployment type, describes the amount of read and write throughput for each 1 tebibyte of storage, in MB/s/TiB. File system throughput capacity is calculated by multiplying ﬁle system storage capacity (TiB) by the PerUnitStorageThroughput (MB/s/TiB). For a 2.4 TiB ﬁle system, provisioning 50 MB/s/TiB of PerUnitStorageThroughput yields 120 MB/s of ﬁle system throughput. You pay for the amount of throughput that you provision.  Valid values for SSD storage: 50, 100, 200. Valid values for HDD storage: 12, 40.
        public let perUnitStorageThroughput: Int?
        /// (Optional) The preferred start time to perform weekly maintenance, formatted d:HH:MM in the UTC time zone, where d is the weekday number, from 1 through 7, beginning with Monday and ending with Sunday.
        public let weeklyMaintenanceStartTime: String?

        public init(autoImportPolicy: AutoImportPolicyType? = nil, automaticBackupRetentionDays: Int? = nil, copyTagsToBackups: Bool? = nil, dailyAutomaticBackupStartTime: String? = nil, deploymentType: LustreDeploymentType? = nil, driveCacheType: DriveCacheType? = nil, exportPath: String? = nil, importedFileChunkSize: Int? = nil, importPath: String? = nil, perUnitStorageThroughput: Int? = nil, weeklyMaintenanceStartTime: String? = nil) {
            self.autoImportPolicy = autoImportPolicy
            self.automaticBackupRetentionDays = automaticBackupRetentionDays
            self.copyTagsToBackups = copyTagsToBackups
            self.dailyAutomaticBackupStartTime = dailyAutomaticBackupStartTime
            self.deploymentType = deploymentType
            self.driveCacheType = driveCacheType
            self.exportPath = exportPath
            self.importedFileChunkSize = importedFileChunkSize
            self.importPath = importPath
            self.perUnitStorageThroughput = perUnitStorageThroughput
            self.weeklyMaintenanceStartTime = weeklyMaintenanceStartTime
        }

        public func validate(name: String) throws {
            try self.validate(self.automaticBackupRetentionDays, name: "automaticBackupRetentionDays", parent: name, max: 90)
            try self.validate(self.automaticBackupRetentionDays, name: "automaticBackupRetentionDays", parent: name, min: 0)
            try self.validate(self.dailyAutomaticBackupStartTime, name: "dailyAutomaticBackupStartTime", parent: name, max: 5)
            try self.validate(self.dailyAutomaticBackupStartTime, name: "dailyAutomaticBackupStartTime", parent: name, min: 5)
            try self.validate(self.dailyAutomaticBackupStartTime, name: "dailyAutomaticBackupStartTime", parent: name, pattern: "^([01]\\d|2[0-3]):?([0-5]\\d)$")
            try self.validate(self.exportPath, name: "exportPath", parent: name, max: 4357)
            try self.validate(self.exportPath, name: "exportPath", parent: name, min: 3)
            try self.validate(self.exportPath, name: "exportPath", parent: name, pattern: "^[^\\u0000\\u0085\\u2028\\u2029\\r\\n]{3,4357}$")
            try self.validate(self.importedFileChunkSize, name: "importedFileChunkSize", parent: name, max: 512_000)
            try self.validate(self.importedFileChunkSize, name: "importedFileChunkSize", parent: name, min: 1)
            try self.validate(self.importPath, name: "importPath", parent: name, max: 4357)
            try self.validate(self.importPath, name: "importPath", parent: name, min: 3)
            try self.validate(self.importPath, name: "importPath", parent: name, pattern: "^[^\\u0000\\u0085\\u2028\\u2029\\r\\n]{3,4357}$")
            try self.validate(self.perUnitStorageThroughput, name: "perUnitStorageThroughput", parent: name, max: 200)
            try self.validate(self.perUnitStorageThroughput, name: "perUnitStorageThroughput", parent: name, min: 12)
            try self.validate(self.weeklyMaintenanceStartTime, name: "weeklyMaintenanceStartTime", parent: name, max: 7)
            try self.validate(self.weeklyMaintenanceStartTime, name: "weeklyMaintenanceStartTime", parent: name, min: 7)
            try self.validate(self.weeklyMaintenanceStartTime, name: "weeklyMaintenanceStartTime", parent: name, pattern: "^[1-7]:([01]\\d|2[0-3]):?([0-5]\\d)$")
        }

        private enum CodingKeys: String, CodingKey {
            case autoImportPolicy = "AutoImportPolicy"
            case automaticBackupRetentionDays = "AutomaticBackupRetentionDays"
            case copyTagsToBackups = "CopyTagsToBackups"
            case dailyAutomaticBackupStartTime = "DailyAutomaticBackupStartTime"
            case deploymentType = "DeploymentType"
            case driveCacheType = "DriveCacheType"
            case exportPath = "ExportPath"
            case importedFileChunkSize = "ImportedFileChunkSize"
            case importPath = "ImportPath"
            case perUnitStorageThroughput = "PerUnitStorageThroughput"
            case weeklyMaintenanceStartTime = "WeeklyMaintenanceStartTime"
        }
    }

    public struct CreateFileSystemRequest: AWSEncodableShape {
        /// A string of up to 64 ASCII characters that Amazon FSx uses to ensure idempotent creation. This string is automatically filled on your behalf when you use the AWS Command Line Interface (AWS CLI) or an AWS SDK.
        public let clientRequestToken: String?
        /// The type of Amazon FSx file system to create, either WINDOWS or LUSTRE.
        public let fileSystemType: FileSystemType
        public let kmsKeyId: String?
        public let lustreConfiguration: CreateFileSystemLustreConfiguration?
        /// A list of IDs specifying the security groups to apply to all network interfaces created for file system access. This list isn't returned in later requests to describe the file system.
        public let securityGroupIds: [String]?
        /// Sets the storage capacity of the file system that you're creating. For Lustre file systems:   For SCRATCH_2 and PERSISTENT_1 SSD deployment types, valid values are 1200 GiB, 2400 GiB, and increments of 2400 GiB.   For PERSISTENT HDD file systems, valid values are increments of 6000 GiB for 12 MB/s/TiB file systems and increments of 1800 GiB for 40 MB/s/TiB file systems.   For SCRATCH_1 deployment type, valid values are 1200 GiB, 2400 GiB, and increments of 3600 GiB.   For Windows file systems:   If StorageType=SSD, valid values are 32 GiB - 65,536 GiB (64 TiB).   If StorageType=HDD, valid values are 2000 GiB - 65,536 GiB (64 TiB).
        public let storageCapacity: Int
        /// Sets the storage type for the file system you're creating. Valid values are SSD and HDD.   Set to SSD to use solid state drive storage. SSD is supported on all Windows and Lustre deployment types.   Set to HDD to use hard disk drive storage. HDD is supported on SINGLE_AZ_2 and MULTI_AZ_1 Windows file system deployment types, and on PERSISTENT Lustre file system deployment types.     Default value is SSD. For more information, see  Storage Type Options in the Amazon FSx for Windows User Guide and Multiple Storage Options in the Amazon FSx for Lustre User Guide.
        public let storageType: StorageType?
        /// Specifies the IDs of the subnets that the file system will be accessible from. For Windows MULTI_AZ_1 file system deployment types, provide exactly two subnet IDs, one for the preferred file server and one for the standby file server. You specify one of these subnets as the preferred subnet using the WindowsConfiguration &gt; PreferredSubnetID property. For Windows SINGLE_AZ_1 and SINGLE_AZ_2 file system deployment types and Lustre file systems, provide exactly one subnet ID. The file server is launched in that subnet's Availability Zone.
        public let subnetIds: [String]
        /// The tags to apply to the file system being created. The key value of the Name tag appears in the console as the file system name.
        public let tags: [Tag]?
        /// The Microsoft Windows configuration for the file system being created.
        public let windowsConfiguration: CreateFileSystemWindowsConfiguration?

        public init(clientRequestToken: String? = CreateFileSystemRequest.idempotencyToken(), fileSystemType: FileSystemType, kmsKeyId: String? = nil, lustreConfiguration: CreateFileSystemLustreConfiguration? = nil, securityGroupIds: [String]? = nil, storageCapacity: Int, storageType: StorageType? = nil, subnetIds: [String], tags: [Tag]? = nil, windowsConfiguration: CreateFileSystemWindowsConfiguration? = nil) {
            self.clientRequestToken = clientRequestToken
            self.fileSystemType = fileSystemType
            self.kmsKeyId = kmsKeyId
            self.lustreConfiguration = lustreConfiguration
            self.securityGroupIds = securityGroupIds
            self.storageCapacity = storageCapacity
            self.storageType = storageType
            self.subnetIds = subnetIds
            self.tags = tags
            self.windowsConfiguration = windowsConfiguration
        }

        public func validate(name: String) throws {
            try self.validate(self.clientRequestToken, name: "clientRequestToken", parent: name, max: 63)
            try self.validate(self.clientRequestToken, name: "clientRequestToken", parent: name, min: 1)
            try self.validate(self.clientRequestToken, name: "clientRequestToken", parent: name, pattern: "[A-za-z0-9_.-]{0,63}$")
            try self.validate(self.kmsKeyId, name: "kmsKeyId", parent: name, max: 2048)
            try self.validate(self.kmsKeyId, name: "kmsKeyId", parent: name, min: 1)
            try self.validate(self.kmsKeyId, name: "kmsKeyId", parent: name, pattern: "^.{1,2048}$")
            try self.lustreConfiguration?.validate(name: "\(name).lustreConfiguration")
            try self.securityGroupIds?.forEach {
                try validate($0, name: "securityGroupIds[]", parent: name, max: 20)
                try validate($0, name: "securityGroupIds[]", parent: name, min: 11)
                try validate($0, name: "securityGroupIds[]", parent: name, pattern: "^(sg-[0-9a-f]{8,})$")
            }
            try self.validate(self.securityGroupIds, name: "securityGroupIds", parent: name, max: 50)
            try self.validate(self.storageCapacity, name: "storageCapacity", parent: name, max: 2_147_483_647)
            try self.validate(self.storageCapacity, name: "storageCapacity", parent: name, min: 0)
            try self.subnetIds.forEach {
                try validate($0, name: "subnetIds[]", parent: name, max: 24)
                try validate($0, name: "subnetIds[]", parent: name, min: 15)
                try validate($0, name: "subnetIds[]", parent: name, pattern: "^(subnet-[0-9a-f]{8,})$")
            }
            try self.validate(self.subnetIds, name: "subnetIds", parent: name, max: 50)
            try self.tags?.forEach {
                try $0.validate(name: "\(name).tags[]")
            }
            try self.validate(self.tags, name: "tags", parent: name, max: 50)
            try self.validate(self.tags, name: "tags", parent: name, min: 1)
            try self.windowsConfiguration?.validate(name: "\(name).windowsConfiguration")
        }

        private enum CodingKeys: String, CodingKey {
            case clientRequestToken = "ClientRequestToken"
            case fileSystemType = "FileSystemType"
            case kmsKeyId = "KmsKeyId"
            case lustreConfiguration = "LustreConfiguration"
            case securityGroupIds = "SecurityGroupIds"
            case storageCapacity = "StorageCapacity"
            case storageType = "StorageType"
            case subnetIds = "SubnetIds"
            case tags = "Tags"
            case windowsConfiguration = "WindowsConfiguration"
        }
    }

    public struct CreateFileSystemResponse: AWSDecodableShape {
        /// The configuration of the file system that was created.
        public let fileSystem: FileSystem?

        public init(fileSystem: FileSystem? = nil) {
            self.fileSystem = fileSystem
        }

        private enum CodingKeys: String, CodingKey {
            case fileSystem = "FileSystem"
        }
    }

    public struct CreateFileSystemWindowsConfiguration: AWSEncodableShape {
        /// The ID for an existing AWS Managed Microsoft Active Directory (AD) instance that the file system should join when it's created.
        public let activeDirectoryId: String?
        /// An array of one or more DNS alias names that you want to associate with the Amazon FSx file system. Aliases allow you to use existing DNS names to access the data in your Amazon FSx file system. You can associate up to 50 aliases with a file system at any time. You can associate additional DNS aliases after you create the file system using the AssociateFileSystemAliases operation. You can remove DNS aliases from the file system after it is created using the DisassociateFileSystemAliases operation. You only need to specify the alias name in the request payload. For more information, see Working with DNS Aliases and Walkthrough 5: Using DNS aliases to access your file system, including additional steps you must take to be able to access your file system using a DNS alias. An alias name has to meet the following requirements:   Formatted as a fully-qualified domain name (FQDN), hostname.domain, for example, accounting.example.com.   Can contain alphanumeric characters and the hyphen (-).   Cannot start or end with a hyphen.   Can start with a numeric.   For DNS alias names, Amazon FSx stores alphabetic characters as lowercase letters (a-z), regardless of how you specify them: as uppercase letters, lowercase letters, or the corresponding letters in escape codes.
        public let aliases: [String]?
        /// The number of days to retain automatic backups. The default is to retain backups for 7 days. Setting this value to 0 disables the creation of automatic backups. The maximum retention period for backups is 90 days.
        public let automaticBackupRetentionDays: Int?
        /// A boolean flag indicating whether tags for the file system should be copied to backups. This value defaults to false. If it's set to true, all tags for the file system are copied to all automatic and user-initiated backups where the user doesn't specify tags. If this value is true, and you specify one or more tags, only the specified tags are copied to backups. If you specify one or more tags when creating a user-initiated backup, no tags are copied from the file system, regardless of this value.
        public let copyTagsToBackups: Bool?
        /// The preferred time to take daily automatic backups, formatted HH:MM in the UTC time zone.
        public let dailyAutomaticBackupStartTime: String?
        /// Specifies the file system deployment type, valid values are the following:    MULTI_AZ_1 - Deploys a high availability file system that is configured for Multi-AZ redundancy to tolerate temporary Availability Zone (AZ) unavailability. You can only deploy a Multi-AZ file system in AWS Regions that have a minimum of three Availability Zones. Also supports HDD storage type    SINGLE_AZ_1 - (Default) Choose to deploy a file system that is configured for single AZ redundancy.    SINGLE_AZ_2 - The latest generation Single AZ file system. Specifies a file system that is configured for single AZ redundancy and supports HDD storage type.   For more information, see  Availability and Durability: Single-AZ and Multi-AZ File Systems.
        public let deploymentType: WindowsDeploymentType?
        /// Required when DeploymentType is set to MULTI_AZ_1. This specifies the subnet in which you want the preferred file server to be located. For in-AWS applications, we recommend that you launch your clients in the same Availability Zone (AZ) as your preferred file server to reduce cross-AZ data transfer costs and minimize latency.
        public let preferredSubnetId: String?
        public let selfManagedActiveDirectoryConfiguration: SelfManagedActiveDirectoryConfiguration?
        /// The throughput of an Amazon FSx file system, measured in megabytes per second, in 2 to the nth increments, between 2^3 (8) and 2^11 (2048).
        public let throughputCapacity: Int
        /// The preferred start time to perform weekly maintenance, formatted d:HH:MM in the UTC time zone, where d is the weekday number, from 1 through 7, beginning with Monday and ending with Sunday.
        public let weeklyMaintenanceStartTime: String?

        public init(activeDirectoryId: String? = nil, aliases: [String]? = nil, automaticBackupRetentionDays: Int? = nil, copyTagsToBackups: Bool? = nil, dailyAutomaticBackupStartTime: String? = nil, deploymentType: WindowsDeploymentType? = nil, preferredSubnetId: String? = nil, selfManagedActiveDirectoryConfiguration: SelfManagedActiveDirectoryConfiguration? = nil, throughputCapacity: Int, weeklyMaintenanceStartTime: String? = nil) {
            self.activeDirectoryId = activeDirectoryId
            self.aliases = aliases
            self.automaticBackupRetentionDays = automaticBackupRetentionDays
            self.copyTagsToBackups = copyTagsToBackups
            self.dailyAutomaticBackupStartTime = dailyAutomaticBackupStartTime
            self.deploymentType = deploymentType
            self.preferredSubnetId = preferredSubnetId
            self.selfManagedActiveDirectoryConfiguration = selfManagedActiveDirectoryConfiguration
            self.throughputCapacity = throughputCapacity
            self.weeklyMaintenanceStartTime = weeklyMaintenanceStartTime
        }

        public func validate(name: String) throws {
            try self.validate(self.activeDirectoryId, name: "activeDirectoryId", parent: name, max: 12)
            try self.validate(self.activeDirectoryId, name: "activeDirectoryId", parent: name, min: 12)
            try self.validate(self.activeDirectoryId, name: "activeDirectoryId", parent: name, pattern: "^d-[0-9a-f]{10}$")
            try self.aliases?.forEach {
                try validate($0, name: "aliases[]", parent: name, max: 253)
                try validate($0, name: "aliases[]", parent: name, min: 4)
                try validate($0, name: "aliases[]", parent: name, pattern: "^[^\\u0000\\u0085\\u2028\\u2029\\r\\n]{4,253}$")
            }
            try self.validate(self.aliases, name: "aliases", parent: name, max: 50)
            try self.validate(self.automaticBackupRetentionDays, name: "automaticBackupRetentionDays", parent: name, max: 90)
            try self.validate(self.automaticBackupRetentionDays, name: "automaticBackupRetentionDays", parent: name, min: 0)
            try self.validate(self.dailyAutomaticBackupStartTime, name: "dailyAutomaticBackupStartTime", parent: name, max: 5)
            try self.validate(self.dailyAutomaticBackupStartTime, name: "dailyAutomaticBackupStartTime", parent: name, min: 5)
            try self.validate(self.dailyAutomaticBackupStartTime, name: "dailyAutomaticBackupStartTime", parent: name, pattern: "^([01]\\d|2[0-3]):?([0-5]\\d)$")
            try self.validate(self.preferredSubnetId, name: "preferredSubnetId", parent: name, max: 24)
            try self.validate(self.preferredSubnetId, name: "preferredSubnetId", parent: name, min: 15)
            try self.validate(self.preferredSubnetId, name: "preferredSubnetId", parent: name, pattern: "^(subnet-[0-9a-f]{8,})$")
            try self.selfManagedActiveDirectoryConfiguration?.validate(name: "\(name).selfManagedActiveDirectoryConfiguration")
            try self.validate(self.throughputCapacity, name: "throughputCapacity", parent: name, max: 2048)
            try self.validate(self.throughputCapacity, name: "throughputCapacity", parent: name, min: 8)
            try self.validate(self.weeklyMaintenanceStartTime, name: "weeklyMaintenanceStartTime", parent: name, max: 7)
            try self.validate(self.weeklyMaintenanceStartTime, name: "weeklyMaintenanceStartTime", parent: name, min: 7)
            try self.validate(self.weeklyMaintenanceStartTime, name: "weeklyMaintenanceStartTime", parent: name, pattern: "^[1-7]:([01]\\d|2[0-3]):?([0-5]\\d)$")
        }

        private enum CodingKeys: String, CodingKey {
            case activeDirectoryId = "ActiveDirectoryId"
            case aliases = "Aliases"
            case automaticBackupRetentionDays = "AutomaticBackupRetentionDays"
            case copyTagsToBackups = "CopyTagsToBackups"
            case dailyAutomaticBackupStartTime = "DailyAutomaticBackupStartTime"
            case deploymentType = "DeploymentType"
            case preferredSubnetId = "PreferredSubnetId"
            case selfManagedActiveDirectoryConfiguration = "SelfManagedActiveDirectoryConfiguration"
            case throughputCapacity = "ThroughputCapacity"
            case weeklyMaintenanceStartTime = "WeeklyMaintenanceStartTime"
        }
    }

    public struct DataRepositoryConfiguration: AWSDecodableShape {
        /// Describes the file system's linked S3 data repository's AutoImportPolicy. The AutoImportPolicy configures how Amazon FSx keeps your file and directory listings up to date as you add or modify objects in your linked S3 bucket. AutoImportPolicy can have the following values:    NONE - (Default) AutoImport is off. Amazon FSx only updates file and directory listings from the linked S3 bucket when the file system is created. FSx does not update file and directory listings for any new or changed objects after choosing this option.    NEW - AutoImport is on. Amazon FSx automatically imports directory listings of any new objects added to the linked S3 bucket that do not currently exist in the FSx file system.     NEW_CHANGED - AutoImport is on. Amazon FSx automatically imports file and directory listings of any new objects added to the S3 bucket and any existing objects that are changed in the S3 bucket after you choose this option.    For more information, see Automatically import updates from your S3 bucket.
        public let autoImportPolicy: AutoImportPolicyType?
        /// The export path to the Amazon S3 bucket (and prefix) that you are using to store new and changed Lustre file system files in S3.
        public let exportPath: String?
        public let failureDetails: DataRepositoryFailureDetails?
        /// For files imported from a data repository, this value determines the stripe count and maximum amount of data per file (in MiB) stored on a single physical disk. The maximum number of disks that a single file can be striped across is limited by the total number of disks that make up the file system. The default chunk size is 1,024 MiB (1 GiB) and can go as high as 512,000 MiB (500 GiB). Amazon S3 objects have a maximum size of 5 TB.
        public let importedFileChunkSize: Int?
        /// The import path to the Amazon S3 bucket (and optional prefix) that you're using as the data repository for your FSx for Lustre file system, for example s3://import-bucket/optional-prefix. If a prefix is specified after the Amazon S3 bucket name, only object keys with that prefix are loaded into the file system.
        public let importPath: String?
        /// Describes the state of the file system's S3 durable data repository, if it is configured with an S3 repository. The lifecycle can have the following values:    CREATING - The data repository configuration between the FSx file system and the linked S3 data repository is being created. The data repository is unavailable.    AVAILABLE - The data repository is available for use.    MISCONFIGURED - Amazon FSx cannot automatically import updates from the S3 bucket until the data repository configuration is corrected. For more information, see Troubleshooting a Misconfigured linked S3 bucket.     UPDATING - The data repository is undergoing a customer initiated update and availability may be impacted.
        public let lifecycle: DataRepositoryLifecycle?

        public init(autoImportPolicy: AutoImportPolicyType? = nil, exportPath: String? = nil, failureDetails: DataRepositoryFailureDetails? = nil, importedFileChunkSize: Int? = nil, importPath: String? = nil, lifecycle: DataRepositoryLifecycle? = nil) {
            self.autoImportPolicy = autoImportPolicy
            self.exportPath = exportPath
            self.failureDetails = failureDetails
            self.importedFileChunkSize = importedFileChunkSize
            self.importPath = importPath
            self.lifecycle = lifecycle
        }

        private enum CodingKeys: String, CodingKey {
            case autoImportPolicy = "AutoImportPolicy"
            case exportPath = "ExportPath"
            case failureDetails = "FailureDetails"
            case importedFileChunkSize = "ImportedFileChunkSize"
            case importPath = "ImportPath"
            case lifecycle = "Lifecycle"
        }
    }

    public struct DataRepositoryFailureDetails: AWSDecodableShape {
        public let message: String?

        public init(message: String? = nil) {
            self.message = message
        }

        private enum CodingKeys: String, CodingKey {
            case message = "Message"
        }
    }

    public struct DataRepositoryTask: AWSDecodableShape {
        public let creationTime: Date
        /// The time that Amazon FSx completed processing the task, populated after the task is complete.
        public let endTime: Date?
        /// Failure message describing why the task failed, it is populated only when Lifecycle is set to FAILED.
        public let failureDetails: DataRepositoryTaskFailureDetails?
        public let fileSystemId: String
        /// The lifecycle status of the data repository task, as follows:    PENDING - Amazon FSx has not started the task.    EXECUTING - Amazon FSx is processing the task.    FAILED - Amazon FSx was not able to complete the task. For example, there may be files the task failed to process. The DataRepositoryTaskFailureDetails property provides more information about task failures.    SUCCEEDED - FSx completed the task successfully.    CANCELED - Amazon FSx canceled the task and it did not complete.    CANCELING - FSx is in process of canceling the task.    You cannot delete an FSx for Lustre file system if there are data repository tasks for the file system in the PENDING or EXECUTING states. Please retry when the data repository task is finished (with a status of CANCELED, SUCCEEDED, or FAILED). You can use the DescribeDataRepositoryTask action to monitor the task status. Contact the FSx team if you need to delete your file system immediately.
        public let lifecycle: DataRepositoryTaskLifecycle
        /// An array of paths on the Amazon FSx for Lustre file system that specify the data for the data repository task to process. For example, in an EXPORT_TO_REPOSITORY task, the paths specify which data to export to the linked data repository. (Default) If Paths is not specified, Amazon FSx uses the file system root directory.
        public let paths: [String]?
        public let report: CompletionReport?
        public let resourceARN: String?
        /// The time that Amazon FSx began processing the task.
        public let startTime: Date?
        /// Provides the status of the number of files that the task has processed successfully and failed to process.
        public let status: DataRepositoryTaskStatus?
        public let tags: [Tag]?
        /// The system-generated, unique 17-digit ID of the data repository task.
        public let taskId: String
        /// The type of data repository task; EXPORT_TO_REPOSITORY is the only type currently supported.
        public let type: DataRepositoryTaskType

        public init(creationTime: Date, endTime: Date? = nil, failureDetails: DataRepositoryTaskFailureDetails? = nil, fileSystemId: String, lifecycle: DataRepositoryTaskLifecycle, paths: [String]? = nil, report: CompletionReport? = nil, resourceARN: String? = nil, startTime: Date? = nil, status: DataRepositoryTaskStatus? = nil, tags: [Tag]? = nil, taskId: String, type: DataRepositoryTaskType) {
            self.creationTime = creationTime
            self.endTime = endTime
            self.failureDetails = failureDetails
            self.fileSystemId = fileSystemId
            self.lifecycle = lifecycle
            self.paths = paths
            self.report = report
            self.resourceARN = resourceARN
            self.startTime = startTime
            self.status = status
            self.tags = tags
            self.taskId = taskId
            self.type = type
        }

        private enum CodingKeys: String, CodingKey {
            case creationTime = "CreationTime"
            case endTime = "EndTime"
            case failureDetails = "FailureDetails"
            case fileSystemId = "FileSystemId"
            case lifecycle = "Lifecycle"
            case paths = "Paths"
            case report = "Report"
            case resourceARN = "ResourceARN"
            case startTime = "StartTime"
            case status = "Status"
            case tags = "Tags"
            case taskId = "TaskId"
            case type = "Type"
        }
    }

    public struct DataRepositoryTaskFailureDetails: AWSDecodableShape {
        public let message: String?

        public init(message: String? = nil) {
            self.message = message
        }

        private enum CodingKeys: String, CodingKey {
            case message = "Message"
        }
    }

    public struct DataRepositoryTaskFilter: AWSEncodableShape {
        /// Name of the task property to use in filtering the tasks returned in the response.   Use file-system-id to retrieve data repository tasks for specific file systems.   Use task-lifecycle to retrieve data repository tasks with one or more specific lifecycle states, as follows: CANCELED, EXECUTING, FAILED, PENDING, and SUCCEEDED.
        public let name: DataRepositoryTaskFilterName?
        /// Use Values to include the specific file system IDs and task lifecycle states for the filters you are using.
        public let values: [String]?

        public init(name: DataRepositoryTaskFilterName? = nil, values: [String]? = nil) {
            self.name = name
            self.values = values
        }

        public func validate(name: String) throws {
            try self.values?.forEach {
                try validate($0, name: "values[]", parent: name, max: 128)
                try validate($0, name: "values[]", parent: name, min: 1)
                try validate($0, name: "values[]", parent: name, pattern: "^[0-9a-zA-Z\\*\\.\\\\/\\?\\-\\_]*$")
            }
            try self.validate(self.values, name: "values", parent: name, max: 20)
        }

        private enum CodingKeys: String, CodingKey {
            case name = "Name"
            case values = "Values"
        }
    }

    public struct DataRepositoryTaskStatus: AWSDecodableShape {
        /// A running total of the number of files that the task failed to process.
        public let failedCount: Int64?
        /// The time at which the task status was last updated.
        public let lastUpdatedTime: Date?
        /// A running total of the number of files that the task has successfully processed.
        public let succeededCount: Int64?
        /// The total number of files that the task will process. While a task is executing, the sum of SucceededCount plus FailedCount may not equal TotalCount. When the task is complete, TotalCount equals the sum of SucceededCount plus FailedCount.
        public let totalCount: Int64?

        public init(failedCount: Int64? = nil, lastUpdatedTime: Date? = nil, succeededCount: Int64? = nil, totalCount: Int64? = nil) {
            self.failedCount = failedCount
            self.lastUpdatedTime = lastUpdatedTime
            self.succeededCount = succeededCount
            self.totalCount = totalCount
        }

        private enum CodingKeys: String, CodingKey {
            case failedCount = "FailedCount"
            case lastUpdatedTime = "LastUpdatedTime"
            case succeededCount = "SucceededCount"
            case totalCount = "TotalCount"
        }
    }

    public struct DeleteBackupRequest: AWSEncodableShape {
        /// The ID of the backup you want to delete.
        public let backupId: String
        /// A string of up to 64 ASCII characters that Amazon FSx uses to ensure idempotent deletion. This is automatically filled on your behalf when using the AWS CLI or SDK.
        public let clientRequestToken: String?

        public init(backupId: String, clientRequestToken: String? = DeleteBackupRequest.idempotencyToken()) {
            self.backupId = backupId
            self.clientRequestToken = clientRequestToken
        }

        public func validate(name: String) throws {
            try self.validate(self.backupId, name: "backupId", parent: name, max: 128)
            try self.validate(self.backupId, name: "backupId", parent: name, min: 12)
            try self.validate(self.backupId, name: "backupId", parent: name, pattern: "^(backup-[0-9a-f]{8,})$")
            try self.validate(self.clientRequestToken, name: "clientRequestToken", parent: name, max: 63)
            try self.validate(self.clientRequestToken, name: "clientRequestToken", parent: name, min: 1)
            try self.validate(self.clientRequestToken, name: "clientRequestToken", parent: name, pattern: "[A-za-z0-9_.-]{0,63}$")
        }

        private enum CodingKeys: String, CodingKey {
            case backupId = "BackupId"
            case clientRequestToken = "ClientRequestToken"
        }
    }

    public struct DeleteBackupResponse: AWSDecodableShape {
        /// The ID of the backup deleted.
        public let backupId: String?
        /// The lifecycle of the backup. Should be DELETED.
        public let lifecycle: BackupLifecycle?

        public init(backupId: String? = nil, lifecycle: BackupLifecycle? = nil) {
            self.backupId = backupId
            self.lifecycle = lifecycle
        }

        private enum CodingKeys: String, CodingKey {
            case backupId = "BackupId"
            case lifecycle = "Lifecycle"
        }
    }

    public struct DeleteFileSystemLustreConfiguration: AWSEncodableShape {
        /// Use if SkipFinalBackup is set to false, and you want to apply an array of tags to the final backup. If you have set the file system property CopyTagsToBackups to true, and you specify one or more FinalBackupTags when deleting a file system, Amazon FSx will not copy any existing file system tags to the backup.
        public let finalBackupTags: [Tag]?
        /// Set SkipFinalBackup to false if you want to take a final backup of the file system you are deleting. By default, Amazon FSx will not take a final backup on your behalf when the DeleteFileSystem operation is invoked. (Default = true)
        public let skipFinalBackup: Bool?

        public init(finalBackupTags: [Tag]? = nil, skipFinalBackup: Bool? = nil) {
            self.finalBackupTags = finalBackupTags
            self.skipFinalBackup = skipFinalBackup
        }

        public func validate(name: String) throws {
            try self.finalBackupTags?.forEach {
                try $0.validate(name: "\(name).finalBackupTags[]")
            }
            try self.validate(self.finalBackupTags, name: "finalBackupTags", parent: name, max: 50)
            try self.validate(self.finalBackupTags, name: "finalBackupTags", parent: name, min: 1)
        }

        private enum CodingKeys: String, CodingKey {
            case finalBackupTags = "FinalBackupTags"
            case skipFinalBackup = "SkipFinalBackup"
        }
    }

    public struct DeleteFileSystemLustreResponse: AWSDecodableShape {
        /// The ID of the final backup for this file system.
        public let finalBackupId: String?
        /// The set of tags applied to the final backup.
        public let finalBackupTags: [Tag]?

        public init(finalBackupId: String? = nil, finalBackupTags: [Tag]? = nil) {
            self.finalBackupId = finalBackupId
            self.finalBackupTags = finalBackupTags
        }

        private enum CodingKeys: String, CodingKey {
            case finalBackupId = "FinalBackupId"
            case finalBackupTags = "FinalBackupTags"
        }
    }

    public struct DeleteFileSystemRequest: AWSEncodableShape {
        /// A string of up to 64 ASCII characters that Amazon FSx uses to ensure idempotent deletion. This is automatically filled on your behalf when using the AWS CLI or SDK.
        public let clientRequestToken: String?
        /// The ID of the file system you want to delete.
        public let fileSystemId: String
        public let lustreConfiguration: DeleteFileSystemLustreConfiguration?
        public let windowsConfiguration: DeleteFileSystemWindowsConfiguration?

        public init(clientRequestToken: String? = DeleteFileSystemRequest.idempotencyToken(), fileSystemId: String, lustreConfiguration: DeleteFileSystemLustreConfiguration? = nil, windowsConfiguration: DeleteFileSystemWindowsConfiguration? = nil) {
            self.clientRequestToken = clientRequestToken
            self.fileSystemId = fileSystemId
            self.lustreConfiguration = lustreConfiguration
            self.windowsConfiguration = windowsConfiguration
        }

        public func validate(name: String) throws {
            try self.validate(self.clientRequestToken, name: "clientRequestToken", parent: name, max: 63)
            try self.validate(self.clientRequestToken, name: "clientRequestToken", parent: name, min: 1)
            try self.validate(self.clientRequestToken, name: "clientRequestToken", parent: name, pattern: "[A-za-z0-9_.-]{0,63}$")
            try self.validate(self.fileSystemId, name: "fileSystemId", parent: name, max: 21)
            try self.validate(self.fileSystemId, name: "fileSystemId", parent: name, min: 11)
            try self.validate(self.fileSystemId, name: "fileSystemId", parent: name, pattern: "^(fs-[0-9a-f]{8,})$")
            try self.lustreConfiguration?.validate(name: "\(name).lustreConfiguration")
            try self.windowsConfiguration?.validate(name: "\(name).windowsConfiguration")
        }

        private enum CodingKeys: String, CodingKey {
            case clientRequestToken = "ClientRequestToken"
            case fileSystemId = "FileSystemId"
            case lustreConfiguration = "LustreConfiguration"
            case windowsConfiguration = "WindowsConfiguration"
        }
    }

    public struct DeleteFileSystemResponse: AWSDecodableShape {
        /// The ID of the file system being deleted.
        public let fileSystemId: String?
        /// The file system lifecycle for the deletion request. Should be DELETING.
        public let lifecycle: FileSystemLifecycle?
        public let lustreResponse: DeleteFileSystemLustreResponse?
        public let windowsResponse: DeleteFileSystemWindowsResponse?

        public init(fileSystemId: String? = nil, lifecycle: FileSystemLifecycle? = nil, lustreResponse: DeleteFileSystemLustreResponse? = nil, windowsResponse: DeleteFileSystemWindowsResponse? = nil) {
            self.fileSystemId = fileSystemId
            self.lifecycle = lifecycle
            self.lustreResponse = lustreResponse
            self.windowsResponse = windowsResponse
        }

        private enum CodingKeys: String, CodingKey {
            case fileSystemId = "FileSystemId"
            case lifecycle = "Lifecycle"
            case lustreResponse = "LustreResponse"
            case windowsResponse = "WindowsResponse"
        }
    }

    public struct DeleteFileSystemWindowsConfiguration: AWSEncodableShape {
        /// A set of tags for your final backup.
        public let finalBackupTags: [Tag]?
        /// By default, Amazon FSx for Windows takes a final backup on your behalf when the DeleteFileSystem operation is invoked. Doing this helps protect you from data loss, and we highly recommend taking the final backup. If you want to skip this backup, use this flag to do so.
        public let skipFinalBackup: Bool?

        public init(finalBackupTags: [Tag]? = nil, skipFinalBackup: Bool? = nil) {
            self.finalBackupTags = finalBackupTags
            self.skipFinalBackup = skipFinalBackup
        }

        public func validate(name: String) throws {
            try self.finalBackupTags?.forEach {
                try $0.validate(name: "\(name).finalBackupTags[]")
            }
            try self.validate(self.finalBackupTags, name: "finalBackupTags", parent: name, max: 50)
            try self.validate(self.finalBackupTags, name: "finalBackupTags", parent: name, min: 1)
        }

        private enum CodingKeys: String, CodingKey {
            case finalBackupTags = "FinalBackupTags"
            case skipFinalBackup = "SkipFinalBackup"
        }
    }

    public struct DeleteFileSystemWindowsResponse: AWSDecodableShape {
        /// The ID of the final backup for this file system.
        public let finalBackupId: String?
        /// The set of tags applied to the final backup.
        public let finalBackupTags: [Tag]?

        public init(finalBackupId: String? = nil, finalBackupTags: [Tag]? = nil) {
            self.finalBackupId = finalBackupId
            self.finalBackupTags = finalBackupTags
        }

        private enum CodingKeys: String, CodingKey {
            case finalBackupId = "FinalBackupId"
            case finalBackupTags = "FinalBackupTags"
        }
    }

    public struct DescribeBackupsRequest: AWSEncodableShape {
        /// IDs of the backups you want to retrieve (String). This overrides any filters. If any IDs are not found, BackupNotFound will be thrown.
        public let backupIds: [String]?
        /// Filters structure. Supported names are file-system-id and backup-type.
        public let filters: [Filter]?
        /// Maximum number of backups to return in the response (integer). This parameter value must be greater than 0. The number of items that Amazon FSx returns is the minimum of the MaxResults parameter specified in the request and the service's internal maximum number of items per page.
        public let maxResults: Int?
        /// Opaque pagination token returned from a previous DescribeBackups operation (String). If a token present, the action continues the list from where the returning call left off.
        public let nextToken: String?

        public init(backupIds: [String]? = nil, filters: [Filter]? = nil, maxResults: Int? = nil, nextToken: String? = nil) {
            self.backupIds = backupIds
            self.filters = filters
            self.maxResults = maxResults
            self.nextToken = nextToken
        }

        public func validate(name: String) throws {
            try self.backupIds?.forEach {
                try validate($0, name: "backupIds[]", parent: name, max: 128)
                try validate($0, name: "backupIds[]", parent: name, min: 12)
                try validate($0, name: "backupIds[]", parent: name, pattern: "^(backup-[0-9a-f]{8,})$")
            }
            try self.validate(self.backupIds, name: "backupIds", parent: name, max: 50)
            try self.filters?.forEach {
                try $0.validate(name: "\(name).filters[]")
            }
            try self.validate(self.filters, name: "filters", parent: name, max: 10)
            try self.validate(self.maxResults, name: "maxResults", parent: name, max: 2_147_483_647)
            try self.validate(self.maxResults, name: "maxResults", parent: name, min: 1)
            try self.validate(self.nextToken, name: "nextToken", parent: name, max: 255)
            try self.validate(self.nextToken, name: "nextToken", parent: name, min: 1)
            try self.validate(self.nextToken, name: "nextToken", parent: name, pattern: "^(?:[A-Za-z0-9+\\/]{4})*(?:[A-Za-z0-9+\\/]{2}==|[A-Za-z0-9+\\/]{3}=)?$")
        }

        private enum CodingKeys: String, CodingKey {
            case backupIds = "BackupIds"
            case filters = "Filters"
            case maxResults = "MaxResults"
            case nextToken = "NextToken"
        }
    }

    public struct DescribeBackupsResponse: AWSDecodableShape {
        /// Any array of backups.
        public let backups: [Backup]?
        /// This is present if there are more backups than returned in the response (String). You can use the NextToken value in the later request to fetch the backups.
        public let nextToken: String?

        public init(backups: [Backup]? = nil, nextToken: String? = nil) {
            self.backups = backups
            self.nextToken = nextToken
        }

        private enum CodingKeys: String, CodingKey {
            case backups = "Backups"
            case nextToken = "NextToken"
        }
    }

    public struct DescribeDataRepositoryTasksRequest: AWSEncodableShape {
        /// (Optional) You can use filters to narrow the DescribeDataRepositoryTasks response to include just tasks for specific file systems, or tasks in a specific lifecycle state.
        public let filters: [DataRepositoryTaskFilter]?
        public let maxResults: Int?
        public let nextToken: String?
        /// (Optional) IDs of the tasks whose descriptions you want to retrieve (String).
        public let taskIds: [String]?

        public init(filters: [DataRepositoryTaskFilter]? = nil, maxResults: Int? = nil, nextToken: String? = nil, taskIds: [String]? = nil) {
            self.filters = filters
            self.maxResults = maxResults
            self.nextToken = nextToken
            self.taskIds = taskIds
        }

        public func validate(name: String) throws {
            try self.filters?.forEach {
                try $0.validate(name: "\(name).filters[]")
            }
            try self.validate(self.filters, name: "filters", parent: name, max: 3)
            try self.validate(self.maxResults, name: "maxResults", parent: name, max: 2_147_483_647)
            try self.validate(self.maxResults, name: "maxResults", parent: name, min: 1)
            try self.validate(self.nextToken, name: "nextToken", parent: name, max: 255)
            try self.validate(self.nextToken, name: "nextToken", parent: name, min: 1)
            try self.validate(self.nextToken, name: "nextToken", parent: name, pattern: "^(?:[A-Za-z0-9+\\/]{4})*(?:[A-Za-z0-9+\\/]{2}==|[A-Za-z0-9+\\/]{3}=)?$")
            try self.taskIds?.forEach {
                try validate($0, name: "taskIds[]", parent: name, max: 128)
                try validate($0, name: "taskIds[]", parent: name, min: 12)
                try validate($0, name: "taskIds[]", parent: name, pattern: "^(task-[0-9a-f]{17,})$")
            }
            try self.validate(self.taskIds, name: "taskIds", parent: name, max: 50)
        }

        private enum CodingKeys: String, CodingKey {
            case filters = "Filters"
            case maxResults = "MaxResults"
            case nextToken = "NextToken"
            case taskIds = "TaskIds"
        }
    }

    public struct DescribeDataRepositoryTasksResponse: AWSDecodableShape {
        /// The collection of data repository task descriptions returned.
        public let dataRepositoryTasks: [DataRepositoryTask]?
        public let nextToken: String?

        public init(dataRepositoryTasks: [DataRepositoryTask]? = nil, nextToken: String? = nil) {
            self.dataRepositoryTasks = dataRepositoryTasks
            self.nextToken = nextToken
        }

        private enum CodingKeys: String, CodingKey {
            case dataRepositoryTasks = "DataRepositoryTasks"
            case nextToken = "NextToken"
        }
    }

    public struct DescribeFileSystemAliasesRequest: AWSEncodableShape {
        public let clientRequestToken: String?
        /// The ID of the file system to return the associated DNS aliases for (String).
        public let fileSystemId: String
        /// Maximum number of DNS aliases to return in the response (integer). This parameter value must be greater than 0. The number of items that Amazon FSx returns is the minimum of the MaxResults parameter specified in the request and the service's internal maximum number of items per page.
        public let maxResults: Int?
        /// Opaque pagination token returned from a previous DescribeFileSystemAliases operation (String). If a token is included in the request, the action continues the list from where the previous returning call left off.
        public let nextToken: String?

        public init(clientRequestToken: String? = DescribeFileSystemAliasesRequest.idempotencyToken(), fileSystemId: String, maxResults: Int? = nil, nextToken: String? = nil) {
            self.clientRequestToken = clientRequestToken
            self.fileSystemId = fileSystemId
            self.maxResults = maxResults
            self.nextToken = nextToken
        }

        public func validate(name: String) throws {
            try self.validate(self.clientRequestToken, name: "clientRequestToken", parent: name, max: 63)
            try self.validate(self.clientRequestToken, name: "clientRequestToken", parent: name, min: 1)
            try self.validate(self.clientRequestToken, name: "clientRequestToken", parent: name, pattern: "[A-za-z0-9_.-]{0,63}$")
            try self.validate(self.fileSystemId, name: "fileSystemId", parent: name, max: 21)
            try self.validate(self.fileSystemId, name: "fileSystemId", parent: name, min: 11)
            try self.validate(self.fileSystemId, name: "fileSystemId", parent: name, pattern: "^(fs-[0-9a-f]{8,})$")
            try self.validate(self.maxResults, name: "maxResults", parent: name, max: 2_147_483_647)
            try self.validate(self.maxResults, name: "maxResults", parent: name, min: 1)
            try self.validate(self.nextToken, name: "nextToken", parent: name, max: 255)
            try self.validate(self.nextToken, name: "nextToken", parent: name, min: 1)
            try self.validate(self.nextToken, name: "nextToken", parent: name, pattern: "^(?:[A-Za-z0-9+\\/]{4})*(?:[A-Za-z0-9+\\/]{2}==|[A-Za-z0-9+\\/]{3}=)?$")
        }

        private enum CodingKeys: String, CodingKey {
            case clientRequestToken = "ClientRequestToken"
            case fileSystemId = "FileSystemId"
            case maxResults = "MaxResults"
            case nextToken = "NextToken"
        }
    }

    public struct DescribeFileSystemAliasesResponse: AWSDecodableShape {
        /// An array of one or more DNS aliases currently associated with the specified file system.
        public let aliases: [Alias]?
        /// Present if there are more DNS aliases than returned in the response (String). You can use the NextToken value in a later request to fetch additional descriptions.
        public let nextToken: String?

        public init(aliases: [Alias]? = nil, nextToken: String? = nil) {
            self.aliases = aliases
            self.nextToken = nextToken
        }

        private enum CodingKeys: String, CodingKey {
            case aliases = "Aliases"
            case nextToken = "NextToken"
        }
    }

    public struct DescribeFileSystemsRequest: AWSEncodableShape {
        /// IDs of the file systems whose descriptions you want to retrieve (String).
        public let fileSystemIds: [String]?
        /// Maximum number of file systems to return in the response (integer). This parameter value must be greater than 0. The number of items that Amazon FSx returns is the minimum of the MaxResults parameter specified in the request and the service's internal maximum number of items per page.
        public let maxResults: Int?
        /// Opaque pagination token returned from a previous DescribeFileSystems operation (String). If a token present, the action continues the list from where the returning call left off.
        public let nextToken: String?

        public init(fileSystemIds: [String]? = nil, maxResults: Int? = nil, nextToken: String? = nil) {
            self.fileSystemIds = fileSystemIds
            self.maxResults = maxResults
            self.nextToken = nextToken
        }

        public func validate(name: String) throws {
            try self.fileSystemIds?.forEach {
                try validate($0, name: "fileSystemIds[]", parent: name, max: 21)
                try validate($0, name: "fileSystemIds[]", parent: name, min: 11)
                try validate($0, name: "fileSystemIds[]", parent: name, pattern: "^(fs-[0-9a-f]{8,})$")
            }
            try self.validate(self.fileSystemIds, name: "fileSystemIds", parent: name, max: 50)
            try self.validate(self.maxResults, name: "maxResults", parent: name, max: 2_147_483_647)
            try self.validate(self.maxResults, name: "maxResults", parent: name, min: 1)
            try self.validate(self.nextToken, name: "nextToken", parent: name, max: 255)
            try self.validate(self.nextToken, name: "nextToken", parent: name, min: 1)
            try self.validate(self.nextToken, name: "nextToken", parent: name, pattern: "^(?:[A-Za-z0-9+\\/]{4})*(?:[A-Za-z0-9+\\/]{2}==|[A-Za-z0-9+\\/]{3}=)?$")
        }

        private enum CodingKeys: String, CodingKey {
            case fileSystemIds = "FileSystemIds"
            case maxResults = "MaxResults"
            case nextToken = "NextToken"
        }
    }

    public struct DescribeFileSystemsResponse: AWSDecodableShape {
        /// An array of file system descriptions.
        public let fileSystems: [FileSystem]?
        /// Present if there are more file systems than returned in the response (String). You can use the NextToken value in the later request to fetch the descriptions.
        public let nextToken: String?

        public init(fileSystems: [FileSystem]? = nil, nextToken: String? = nil) {
            self.fileSystems = fileSystems
            self.nextToken = nextToken
        }

        private enum CodingKeys: String, CodingKey {
            case fileSystems = "FileSystems"
            case nextToken = "NextToken"
        }
    }

    public struct DisassociateFileSystemAliasesRequest: AWSEncodableShape {
        /// An array of one or more DNS alias names to disassociate, or remove, from the file system.
        public let aliases: [String]
        public let clientRequestToken: String?
        /// Specifies the file system from which to disassociate the DNS aliases.
        public let fileSystemId: String

        public init(aliases: [String], clientRequestToken: String? = DisassociateFileSystemAliasesRequest.idempotencyToken(), fileSystemId: String) {
            self.aliases = aliases
            self.clientRequestToken = clientRequestToken
            self.fileSystemId = fileSystemId
        }

        public func validate(name: String) throws {
            try self.aliases.forEach {
                try validate($0, name: "aliases[]", parent: name, max: 253)
                try validate($0, name: "aliases[]", parent: name, min: 4)
                try validate($0, name: "aliases[]", parent: name, pattern: "^[^\\u0000\\u0085\\u2028\\u2029\\r\\n]{4,253}$")
            }
            try self.validate(self.aliases, name: "aliases", parent: name, max: 50)
            try self.validate(self.clientRequestToken, name: "clientRequestToken", parent: name, max: 63)
            try self.validate(self.clientRequestToken, name: "clientRequestToken", parent: name, min: 1)
            try self.validate(self.clientRequestToken, name: "clientRequestToken", parent: name, pattern: "[A-za-z0-9_.-]{0,63}$")
            try self.validate(self.fileSystemId, name: "fileSystemId", parent: name, max: 21)
            try self.validate(self.fileSystemId, name: "fileSystemId", parent: name, min: 11)
            try self.validate(self.fileSystemId, name: "fileSystemId", parent: name, pattern: "^(fs-[0-9a-f]{8,})$")
        }

        private enum CodingKeys: String, CodingKey {
            case aliases = "Aliases"
            case clientRequestToken = "ClientRequestToken"
            case fileSystemId = "FileSystemId"
        }
    }

    public struct DisassociateFileSystemAliasesResponse: AWSDecodableShape {
        /// An array of one or more DNS aliases that Amazon FSx is attempting to disassociate from the file system.
        public let aliases: [Alias]?

        public init(aliases: [Alias]? = nil) {
            self.aliases = aliases
        }

        private enum CodingKeys: String, CodingKey {
            case aliases = "Aliases"
        }
    }

    public struct FileSystem: AWSDecodableShape {
        /// A list of administrative actions for the file system that are in process or waiting to be processed. Administrative actions describe changes to the Windows file system that you have initiated using the UpdateFileSystem action.
        public let administrativeActions: [AdministrativeAction]?
        /// The time that the file system was created, in seconds (since 1970-01-01T00:00:00Z), also known as Unix time.
        public let creationTime: Date?
        /// The DNS name for the file system.
        public let dNSName: String?
        public let failureDetails: FileSystemFailureDetails?
        /// The system-generated, unique 17-digit ID of the file system.
        public let fileSystemId: String?
        /// The type of Amazon FSx file system, either LUSTRE or WINDOWS.
        public let fileSystemType: FileSystemType?
        /// The ID of the AWS Key Management Service (AWS KMS) key used to encrypt the file system's data for Amazon FSx for Windows File Server file systems and persistent Amazon FSx for Lustre file systems at rest. In either case, if not specified, the Amazon FSx managed key is used. The scratch Amazon FSx for Lustre file systems are always encrypted at rest using Amazon FSx managed keys. For more information, see Encrypt in the AWS Key Management Service API Reference.
        public let kmsKeyId: String?
        /// The lifecycle status of the file system, following are the possible values and what they mean:    AVAILABLE - The file system is in a healthy state, and is reachable and available for use.    CREATING - Amazon FSx is creating the new file system.    DELETING - Amazon FSx is deleting an existing file system.    FAILED - An existing file system has experienced an unrecoverable failure. When creating a new file system, Amazon FSx was unable to create the file system.    MISCONFIGURED indicates that the file system is in a failed but recoverable state.    UPDATING indicates that the file system is undergoing a customer initiated update.
        public let lifecycle: FileSystemLifecycle?
        public let lustreConfiguration: LustreFileSystemConfiguration?
        /// The IDs of the elastic network interface from which a specific file system is accessible. The elastic network interface is automatically created in the same VPC that the Amazon FSx file system was created in. For more information, see Elastic Network Interfaces in the Amazon EC2 User Guide.  For an Amazon FSx for Windows File Server file system, you can have one network interface ID. For an Amazon FSx for Lustre file system, you can have more than one.
        public let networkInterfaceIds: [String]?
        /// The AWS account that created the file system. If the file system was created by an AWS Identity and Access Management (IAM) user, the AWS account to which the IAM user belongs is the owner.
        public let ownerId: String?
        /// The Amazon Resource Name (ARN) for the file system resource.
        public let resourceARN: String?
        /// The storage capacity of the file system in gibibytes (GiB).
        public let storageCapacity: Int?
        /// The storage type of the file system. Valid values are SSD and HDD. If set to SSD, the file system uses solid state drive storage. If set to HDD, the file system uses hard disk drive storage.
        public let storageType: StorageType?
        /// Specifies the IDs of the subnets that the file system is accessible from. For Windows MULTI_AZ_1 file system deployment type, there are two subnet IDs, one for the preferred file server and one for the standby file server. The preferred file server subnet identified in the PreferredSubnetID property. All other file systems have only one subnet ID. For Lustre file systems, and Single-AZ Windows file systems, this is the ID of the subnet that contains the endpoint for the file system. For MULTI_AZ_1 Windows file systems, the endpoint for the file system is available in the PreferredSubnetID.
        public let subnetIds: [String]?
        /// The tags to associate with the file system. For more information, see Tagging Your Amazon EC2 Resources in the Amazon EC2 User Guide.
        public let tags: [Tag]?
        /// The ID of the primary VPC for the file system.
        public let vpcId: String?
        /// The configuration for this Microsoft Windows file system.
        public let windowsConfiguration: WindowsFileSystemConfiguration?

        public init(administrativeActions: [AdministrativeAction]? = nil, creationTime: Date? = nil, dNSName: String? = nil, failureDetails: FileSystemFailureDetails? = nil, fileSystemId: String? = nil, fileSystemType: FileSystemType? = nil, kmsKeyId: String? = nil, lifecycle: FileSystemLifecycle? = nil, lustreConfiguration: LustreFileSystemConfiguration? = nil, networkInterfaceIds: [String]? = nil, ownerId: String? = nil, resourceARN: String? = nil, storageCapacity: Int? = nil, storageType: StorageType? = nil, subnetIds: [String]? = nil, tags: [Tag]? = nil, vpcId: String? = nil, windowsConfiguration: WindowsFileSystemConfiguration? = nil) {
            self.administrativeActions = administrativeActions
            self.creationTime = creationTime
            self.dNSName = dNSName
            self.failureDetails = failureDetails
            self.fileSystemId = fileSystemId
            self.fileSystemType = fileSystemType
            self.kmsKeyId = kmsKeyId
            self.lifecycle = lifecycle
            self.lustreConfiguration = lustreConfiguration
            self.networkInterfaceIds = networkInterfaceIds
            self.ownerId = ownerId
            self.resourceARN = resourceARN
            self.storageCapacity = storageCapacity
            self.storageType = storageType
            self.subnetIds = subnetIds
            self.tags = tags
            self.vpcId = vpcId
            self.windowsConfiguration = windowsConfiguration
        }

        private enum CodingKeys: String, CodingKey {
            case administrativeActions = "AdministrativeActions"
            case creationTime = "CreationTime"
            case dNSName = "DNSName"
            case failureDetails = "FailureDetails"
            case fileSystemId = "FileSystemId"
            case fileSystemType = "FileSystemType"
            case kmsKeyId = "KmsKeyId"
            case lifecycle = "Lifecycle"
            case lustreConfiguration = "LustreConfiguration"
            case networkInterfaceIds = "NetworkInterfaceIds"
            case ownerId = "OwnerId"
            case resourceARN = "ResourceARN"
            case storageCapacity = "StorageCapacity"
            case storageType = "StorageType"
            case subnetIds = "SubnetIds"
            case tags = "Tags"
            case vpcId = "VpcId"
            case windowsConfiguration = "WindowsConfiguration"
        }
    }

    public struct FileSystemFailureDetails: AWSDecodableShape {
        /// A message describing any failures that occurred during file system creation.
        public let message: String?

        public init(message: String? = nil) {
            self.message = message
        }

        private enum CodingKeys: String, CodingKey {
            case message = "Message"
        }
    }

    public struct Filter: AWSEncodableShape {
        /// The name for this filter.
        public let name: FilterName?
        /// The values of the filter. These are all the values for any of the applied filters.
        public let values: [String]?

        public init(name: FilterName? = nil, values: [String]? = nil) {
            self.name = name
            self.values = values
        }

        public func validate(name: String) throws {
            try self.values?.forEach {
                try validate($0, name: "values[]", parent: name, max: 128)
                try validate($0, name: "values[]", parent: name, min: 1)
                try validate($0, name: "values[]", parent: name, pattern: "^[0-9a-zA-Z\\*\\.\\\\/\\?\\-\\_]*$")
            }
            try self.validate(self.values, name: "values", parent: name, max: 20)
        }

        private enum CodingKeys: String, CodingKey {
            case name = "Name"
            case values = "Values"
        }
    }

    public struct ListTagsForResourceRequest: AWSEncodableShape {
        /// Maximum number of tags to return in the response (integer). This parameter value must be greater than 0. The number of items that Amazon FSx returns is the minimum of the MaxResults parameter specified in the request and the service's internal maximum number of items per page.
        public let maxResults: Int?
        /// Opaque pagination token returned from a previous ListTagsForResource operation (String). If a token present, the action continues the list from where the returning call left off.
        public let nextToken: String?
        /// The ARN of the Amazon FSx resource that will have its tags listed.
        public let resourceARN: String

        public init(maxResults: Int? = nil, nextToken: String? = nil, resourceARN: String) {
            self.maxResults = maxResults
            self.nextToken = nextToken
            self.resourceARN = resourceARN
        }

        public func validate(name: String) throws {
            try self.validate(self.maxResults, name: "maxResults", parent: name, max: 2_147_483_647)
            try self.validate(self.maxResults, name: "maxResults", parent: name, min: 1)
            try self.validate(self.nextToken, name: "nextToken", parent: name, max: 255)
            try self.validate(self.nextToken, name: "nextToken", parent: name, min: 1)
            try self.validate(self.nextToken, name: "nextToken", parent: name, pattern: "^(?:[A-Za-z0-9+\\/]{4})*(?:[A-Za-z0-9+\\/]{2}==|[A-Za-z0-9+\\/]{3}=)?$")
            try self.validate(self.resourceARN, name: "resourceARN", parent: name, max: 512)
            try self.validate(self.resourceARN, name: "resourceARN", parent: name, min: 8)
            try self.validate(self.resourceARN, name: "resourceARN", parent: name, pattern: "^arn:(?=[^:]+:fsx:[^:]+:\\d{12}:)((|(?=[a-z0-9-.]{1,63})(?!\\d{1,3}(\\.\\d{1,3}){3})(?![^:]*-{2})(?![^:]*-\\.)(?![^:]*\\.-)[a-z0-9].*(?<!-)):){4}(?!/).{0,1024}$")
        }

        private enum CodingKeys: String, CodingKey {
            case maxResults = "MaxResults"
            case nextToken = "NextToken"
            case resourceARN = "ResourceARN"
        }
    }

    public struct ListTagsForResourceResponse: AWSDecodableShape {
        /// This is present if there are more tags than returned in the response (String). You can use the NextToken value in the later request to fetch the tags.
        public let nextToken: String?
        /// A list of tags on the resource.
        public let tags: [Tag]?

        public init(nextToken: String? = nil, tags: [Tag]? = nil) {
            self.nextToken = nextToken
            self.tags = tags
        }

        private enum CodingKeys: String, CodingKey {
            case nextToken = "NextToken"
            case tags = "Tags"
        }
    }

    public struct LustreFileSystemConfiguration: AWSDecodableShape {
        public let automaticBackupRetentionDays: Int?
        /// A boolean flag indicating whether tags on the file system should be copied to backups. If it's set to true, all tags on the file system are copied to all automatic backups and any user-initiated backups where the user doesn't specify any tags. If this value is true, and you specify one or more tags, only the specified tags are copied to backups. If you specify one or more tags when creating a user-initiated backup, no tags are copied from the file system, regardless of this value. (Default = false)
        public let copyTagsToBackups: Bool?
        public let dailyAutomaticBackupStartTime: String?
        public let dataRepositoryConfiguration: DataRepositoryConfiguration?
        /// The deployment type of the FSX for Lustre file system. Scratch deployment type is designed for temporary storage and shorter-term processing of data.  SCRATCH_1 and SCRATCH_2 deployment types are best suited for when you need temporary storage and shorter-term processing of data. The SCRATCH_2 deployment type provides in-transit encryption of data and higher burst throughput capacity than SCRATCH_1. The PERSISTENT_1 deployment type is used for longer-term storage and workloads and encryption of data in transit. To learn more about deployment types, see  FSx for Lustre Deployment Options. (Default = SCRATCH_1)
        public let deploymentType: LustreDeploymentType?
        /// The type of drive cache used by PERSISTENT_1 file systems that are provisioned with HDD storage devices. This parameter is required when storage type is HDD. Set to READ, improve the performance for frequently accessed files and allows 20% of the total storage capacity of the file system to be cached.  This parameter is required when StorageType is set to HDD.
        public let driveCacheType: DriveCacheType?
        /// You use the MountName value when mounting the file system. For the SCRATCH_1 deployment type, this value is always "fsx". For SCRATCH_2 and PERSISTENT_1 deployment types, this value is a string that is unique within an AWS Region.
        public let mountName: String?
        ///  Per unit storage throughput represents the megabytes per second of read or write throughput per 1 tebibyte of storage provisioned. File system throughput capacity is equal to Storage capacity (TiB) * PerUnitStorageThroughput (MB/s/TiB). This option is only valid for PERSISTENT_1 deployment types.  Valid values for SSD storage: 50, 100, 200. Valid values for HDD storage: 12, 40.
        public let perUnitStorageThroughput: Int?
        /// The preferred start time to perform weekly maintenance, formatted d:HH:MM in the UTC time zone. d is the weekday number, from 1 through 7, beginning with Monday and ending with Sunday.
        public let weeklyMaintenanceStartTime: String?

        public init(automaticBackupRetentionDays: Int? = nil, copyTagsToBackups: Bool? = nil, dailyAutomaticBackupStartTime: String? = nil, dataRepositoryConfiguration: DataRepositoryConfiguration? = nil, deploymentType: LustreDeploymentType? = nil, driveCacheType: DriveCacheType? = nil, mountName: String? = nil, perUnitStorageThroughput: Int? = nil, weeklyMaintenanceStartTime: String? = nil) {
            self.automaticBackupRetentionDays = automaticBackupRetentionDays
            self.copyTagsToBackups = copyTagsToBackups
            self.dailyAutomaticBackupStartTime = dailyAutomaticBackupStartTime
            self.dataRepositoryConfiguration = dataRepositoryConfiguration
            self.deploymentType = deploymentType
            self.driveCacheType = driveCacheType
            self.mountName = mountName
            self.perUnitStorageThroughput = perUnitStorageThroughput
            self.weeklyMaintenanceStartTime = weeklyMaintenanceStartTime
        }

        private enum CodingKeys: String, CodingKey {
            case automaticBackupRetentionDays = "AutomaticBackupRetentionDays"
            case copyTagsToBackups = "CopyTagsToBackups"
            case dailyAutomaticBackupStartTime = "DailyAutomaticBackupStartTime"
            case dataRepositoryConfiguration = "DataRepositoryConfiguration"
            case deploymentType = "DeploymentType"
            case driveCacheType = "DriveCacheType"
            case mountName = "MountName"
            case perUnitStorageThroughput = "PerUnitStorageThroughput"
            case weeklyMaintenanceStartTime = "WeeklyMaintenanceStartTime"
        }
    }

    public struct SelfManagedActiveDirectoryAttributes: AWSDecodableShape {
        /// A list of up to two IP addresses of DNS servers or domain controllers in the self-managed AD directory.
        public let dnsIps: [String]?
        /// The fully qualified domain name of the self-managed AD directory.
        public let domainName: String?
        /// The name of the domain group whose members have administrative privileges for the FSx file system.
        public let fileSystemAdministratorsGroup: String?
        /// The fully qualified distinguished name of the organizational unit within the self-managed AD directory to which the Windows File Server instance is joined.
        public let organizationalUnitDistinguishedName: String?
        /// The user name for the service account on your self-managed AD domain that FSx uses to join to your AD domain.
        public let userName: String?

        public init(dnsIps: [String]? = nil, domainName: String? = nil, fileSystemAdministratorsGroup: String? = nil, organizationalUnitDistinguishedName: String? = nil, userName: String? = nil) {
            self.dnsIps = dnsIps
            self.domainName = domainName
            self.fileSystemAdministratorsGroup = fileSystemAdministratorsGroup
            self.organizationalUnitDistinguishedName = organizationalUnitDistinguishedName
            self.userName = userName
        }

        private enum CodingKeys: String, CodingKey {
            case dnsIps = "DnsIps"
            case domainName = "DomainName"
            case fileSystemAdministratorsGroup = "FileSystemAdministratorsGroup"
            case organizationalUnitDistinguishedName = "OrganizationalUnitDistinguishedName"
            case userName = "UserName"
        }
    }

    public struct SelfManagedActiveDirectoryConfiguration: AWSEncodableShape {
        /// A list of up to two IP addresses of DNS servers or domain controllers in the self-managed AD directory. The IP addresses need to be either in the same VPC CIDR range as the one in which your Amazon FSx file system is being created, or in the private IP version 4 (IPv4) address ranges, as specified in RFC 1918:   10.0.0.0 - 10.255.255.255 (10/8 prefix)   172.16.0.0 - 172.31.255.255 (172.16/12 prefix)   192.168.0.0 - 192.168.255.255 (192.168/16 prefix)
        public let dnsIps: [String]
        /// The fully qualified domain name of the self-managed AD directory, such as corp.example.com.
        public let domainName: String
        /// (Optional) The name of the domain group whose members are granted administrative privileges for the file system. Administrative privileges include taking ownership of files and folders, setting audit controls (audit ACLs) on files and folders, and administering the file system remotely by using the FSx Remote PowerShell. The group that you specify must already exist in your domain. If you don't provide one, your AD domain's Domain Admins group is used.
        public let fileSystemAdministratorsGroup: String?
        /// (Optional) The fully qualified distinguished name of the organizational unit within your self-managed AD directory that the Windows File Server instance will join. Amazon FSx only accepts OU as the direct parent of the file system. An example is OU=FSx,DC=yourdomain,DC=corp,DC=com. To learn more, see RFC 2253. If none is provided, the FSx file system is created in the default location of your self-managed AD directory.   Only Organizational Unit (OU) objects can be the direct parent of the file system that you're creating.
        public let organizationalUnitDistinguishedName: String?
        /// The password for the service account on your self-managed AD domain that Amazon FSx will use to join to your AD domain.
        public let password: String
        /// The user name for the service account on your self-managed AD domain that Amazon FSx will use to join to your AD domain. This account must have the permission to join computers to the domain in the organizational unit provided in OrganizationalUnitDistinguishedName, or in the default location of your AD domain.
        public let userName: String

        public init(dnsIps: [String], domainName: String, fileSystemAdministratorsGroup: String? = nil, organizationalUnitDistinguishedName: String? = nil, password: String, userName: String) {
            self.dnsIps = dnsIps
            self.domainName = domainName
            self.fileSystemAdministratorsGroup = fileSystemAdministratorsGroup
            self.organizationalUnitDistinguishedName = organizationalUnitDistinguishedName
            self.password = password
            self.userName = userName
        }

        public func validate(name: String) throws {
            try self.dnsIps.forEach {
                try validate($0, name: "dnsIps[]", parent: name, max: 15)
                try validate($0, name: "dnsIps[]", parent: name, min: 7)
                try validate($0, name: "dnsIps[]", parent: name, pattern: "^(([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.){3}([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])$")
            }
            try self.validate(self.dnsIps, name: "dnsIps", parent: name, max: 2)
            try self.validate(self.dnsIps, name: "dnsIps", parent: name, min: 1)
            try self.validate(self.domainName, name: "domainName", parent: name, max: 255)
            try self.validate(self.domainName, name: "domainName", parent: name, min: 1)
            try self.validate(self.domainName, name: "domainName", parent: name, pattern: "^[^\\u0000\\u0085\\u2028\\u2029\\r\\n]{1,255}$")
            try self.validate(self.fileSystemAdministratorsGroup, name: "fileSystemAdministratorsGroup", parent: name, max: 256)
            try self.validate(self.fileSystemAdministratorsGroup, name: "fileSystemAdministratorsGroup", parent: name, min: 1)
            try self.validate(self.fileSystemAdministratorsGroup, name: "fileSystemAdministratorsGroup", parent: name, pattern: "^[^\\u0000\\u0085\\u2028\\u2029\\r\\n]{1,256}$")
            try self.validate(self.organizationalUnitDistinguishedName, name: "organizationalUnitDistinguishedName", parent: name, max: 2000)
            try self.validate(self.organizationalUnitDistinguishedName, name: "organizationalUnitDistinguishedName", parent: name, min: 1)
            try self.validate(self.organizationalUnitDistinguishedName, name: "organizationalUnitDistinguishedName", parent: name, pattern: "^[^\\u0000\\u0085\\u2028\\u2029\\r\\n]{1,2000}$")
            try self.validate(self.password, name: "password", parent: name, max: 256)
            try self.validate(self.password, name: "password", parent: name, min: 1)
            try self.validate(self.password, name: "password", parent: name, pattern: "^.{1,256}$")
            try self.validate(self.userName, name: "userName", parent: name, max: 256)
            try self.validate(self.userName, name: "userName", parent: name, min: 1)
            try self.validate(self.userName, name: "userName", parent: name, pattern: "^[^\\u0000\\u0085\\u2028\\u2029\\r\\n]{1,256}$")
        }

        private enum CodingKeys: String, CodingKey {
            case dnsIps = "DnsIps"
            case domainName = "DomainName"
            case fileSystemAdministratorsGroup = "FileSystemAdministratorsGroup"
            case organizationalUnitDistinguishedName = "OrganizationalUnitDistinguishedName"
            case password = "Password"
            case userName = "UserName"
        }
    }

    public struct SelfManagedActiveDirectoryConfigurationUpdates: AWSEncodableShape {
        /// A list of up to two IP addresses of DNS servers or domain controllers in the self-managed AD directory.
        public let dnsIps: [String]?
        /// The password for the service account on your self-managed AD domain that Amazon FSx will use to join to your AD domain.
        public let password: String?
        /// The user name for the service account on your self-managed AD domain that Amazon FSx will use to join to your AD domain. This account must have the permission to join computers to the domain in the organizational unit provided in OrganizationalUnitDistinguishedName.
        public let userName: String?

        public init(dnsIps: [String]? = nil, password: String? = nil, userName: String? = nil) {
            self.dnsIps = dnsIps
            self.password = password
            self.userName = userName
        }

        public func validate(name: String) throws {
            try self.dnsIps?.forEach {
                try validate($0, name: "dnsIps[]", parent: name, max: 15)
                try validate($0, name: "dnsIps[]", parent: name, min: 7)
                try validate($0, name: "dnsIps[]", parent: name, pattern: "^(([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.){3}([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])$")
            }
            try self.validate(self.dnsIps, name: "dnsIps", parent: name, max: 2)
            try self.validate(self.dnsIps, name: "dnsIps", parent: name, min: 1)
            try self.validate(self.password, name: "password", parent: name, max: 256)
            try self.validate(self.password, name: "password", parent: name, min: 1)
            try self.validate(self.password, name: "password", parent: name, pattern: "^.{1,256}$")
            try self.validate(self.userName, name: "userName", parent: name, max: 256)
            try self.validate(self.userName, name: "userName", parent: name, min: 1)
            try self.validate(self.userName, name: "userName", parent: name, pattern: "^[^\\u0000\\u0085\\u2028\\u2029\\r\\n]{1,256}$")
        }

        private enum CodingKeys: String, CodingKey {
            case dnsIps = "DnsIps"
            case password = "Password"
            case userName = "UserName"
        }
    }

    public struct Tag: AWSEncodableShape & AWSDecodableShape {
        /// A value that specifies the TagKey, the name of the tag. Tag keys must be unique for the resource to which they are attached.
        public let key: String
        /// A value that specifies the TagValue, the value assigned to the corresponding tag key. Tag values can be null and don't have to be unique in a tag set. For example, you can have a key-value pair in a tag set of finances : April and also of payroll : April.
        public let value: String

        public init(key: String, value: String) {
            self.key = key
            self.value = value
        }

        public func validate(name: String) throws {
            try self.validate(self.key, name: "key", parent: name, max: 128)
            try self.validate(self.key, name: "key", parent: name, min: 1)
            try self.validate(self.key, name: "key", parent: name, pattern: "^([\\p{L}\\p{Z}\\p{N}_.:/=+\\-@]*)$")
            try self.validate(self.value, name: "value", parent: name, max: 256)
            try self.validate(self.value, name: "value", parent: name, min: 0)
            try self.validate(self.value, name: "value", parent: name, pattern: "^([\\p{L}\\p{Z}\\p{N}_.:/=+\\-@]*)$")
        }

        private enum CodingKeys: String, CodingKey {
            case key = "Key"
            case value = "Value"
        }
    }

    public struct TagResourceRequest: AWSEncodableShape {
        /// The Amazon Resource Name (ARN) of the Amazon FSx resource that you want to tag.
        public let resourceARN: String
        /// A list of tags for the resource. If a tag with a given key already exists, the value is replaced by the one specified in this parameter.
        public let tags: [Tag]

        public init(resourceARN: String, tags: [Tag]) {
            self.resourceARN = resourceARN
            self.tags = tags
        }

        public func validate(name: String) throws {
            try self.validate(self.resourceARN, name: "resourceARN", parent: name, max: 512)
            try self.validate(self.resourceARN, name: "resourceARN", parent: name, min: 8)
            try self.validate(self.resourceARN, name: "resourceARN", parent: name, pattern: "^arn:(?=[^:]+:fsx:[^:]+:\\d{12}:)((|(?=[a-z0-9-.]{1,63})(?!\\d{1,3}(\\.\\d{1,3}){3})(?![^:]*-{2})(?![^:]*-\\.)(?![^:]*\\.-)[a-z0-9].*(?<!-)):){4}(?!/).{0,1024}$")
            try self.tags.forEach {
                try $0.validate(name: "\(name).tags[]")
            }
            try self.validate(self.tags, name: "tags", parent: name, max: 50)
            try self.validate(self.tags, name: "tags", parent: name, min: 1)
        }

        private enum CodingKeys: String, CodingKey {
            case resourceARN = "ResourceARN"
            case tags = "Tags"
        }
    }

    public struct TagResourceResponse: AWSDecodableShape {
        public init() {}
    }

    public struct UntagResourceRequest: AWSEncodableShape {
        /// The ARN of the Amazon FSx resource to untag.
        public let resourceARN: String
        /// A list of keys of tags on the resource to untag. In case the tag key doesn't exist, the call will still succeed to be idempotent.
        public let tagKeys: [String]

        public init(resourceARN: String, tagKeys: [String]) {
            self.resourceARN = resourceARN
            self.tagKeys = tagKeys
        }

        public func validate(name: String) throws {
            try self.validate(self.resourceARN, name: "resourceARN", parent: name, max: 512)
            try self.validate(self.resourceARN, name: "resourceARN", parent: name, min: 8)
            try self.validate(self.resourceARN, name: "resourceARN", parent: name, pattern: "^arn:(?=[^:]+:fsx:[^:]+:\\d{12}:)((|(?=[a-z0-9-.]{1,63})(?!\\d{1,3}(\\.\\d{1,3}){3})(?![^:]*-{2})(?![^:]*-\\.)(?![^:]*\\.-)[a-z0-9].*(?<!-)):){4}(?!/).{0,1024}$")
            try self.tagKeys.forEach {
                try validate($0, name: "tagKeys[]", parent: name, max: 128)
                try validate($0, name: "tagKeys[]", parent: name, min: 1)
                try validate($0, name: "tagKeys[]", parent: name, pattern: "^([\\p{L}\\p{Z}\\p{N}_.:/=+\\-@]*)$")
            }
            try self.validate(self.tagKeys, name: "tagKeys", parent: name, max: 50)
            try self.validate(self.tagKeys, name: "tagKeys", parent: name, min: 1)
        }

        private enum CodingKeys: String, CodingKey {
            case resourceARN = "ResourceARN"
            case tagKeys = "TagKeys"
        }
    }

    public struct UntagResourceResponse: AWSDecodableShape {
        public init() {}
    }

    public struct UpdateFileSystemLustreConfiguration: AWSEncodableShape {
        ///  (Optional) When you create your file system, your existing S3 objects appear as file and directory listings. Use this property to choose how Amazon FSx keeps your file and directory listing up to date as you add or modify objects in your linked S3 bucket. AutoImportPolicy can have the following values:    NONE - (Default) AutoImport is off. Amazon FSx only updates file and directory listings from the linked S3 bucket when the file system is created. FSx does not update the file and directory listing for any new or changed objects after choosing this option.    NEW - AutoImport is on. Amazon FSx automatically imports directory listings of any new objects added to the linked S3 bucket that do not currently exist in the FSx file system.     NEW_CHANGED - AutoImport is on. Amazon FSx automatically imports file and directory listings of any new objects added to the S3 bucket and any existing objects that are changed in the S3 bucket after you choose this option.    For more information, see Automatically import updates from your S3 bucket.
        public let autoImportPolicy: AutoImportPolicyType?
        public let automaticBackupRetentionDays: Int?
        public let dailyAutomaticBackupStartTime: String?
        /// (Optional) The preferred start time to perform weekly maintenance, formatted d:HH:MM in the UTC time zone. d is the weekday number, from 1 through 7, beginning with Monday and ending with Sunday.
        public let weeklyMaintenanceStartTime: String?

        public init(autoImportPolicy: AutoImportPolicyType? = nil, automaticBackupRetentionDays: Int? = nil, dailyAutomaticBackupStartTime: String? = nil, weeklyMaintenanceStartTime: String? = nil) {
            self.autoImportPolicy = autoImportPolicy
            self.automaticBackupRetentionDays = automaticBackupRetentionDays
            self.dailyAutomaticBackupStartTime = dailyAutomaticBackupStartTime
            self.weeklyMaintenanceStartTime = weeklyMaintenanceStartTime
        }

        public func validate(name: String) throws {
            try self.validate(self.automaticBackupRetentionDays, name: "automaticBackupRetentionDays", parent: name, max: 90)
            try self.validate(self.automaticBackupRetentionDays, name: "automaticBackupRetentionDays", parent: name, min: 0)
            try self.validate(self.dailyAutomaticBackupStartTime, name: "dailyAutomaticBackupStartTime", parent: name, max: 5)
            try self.validate(self.dailyAutomaticBackupStartTime, name: "dailyAutomaticBackupStartTime", parent: name, min: 5)
            try self.validate(self.dailyAutomaticBackupStartTime, name: "dailyAutomaticBackupStartTime", parent: name, pattern: "^([01]\\d|2[0-3]):?([0-5]\\d)$")
            try self.validate(self.weeklyMaintenanceStartTime, name: "weeklyMaintenanceStartTime", parent: name, max: 7)
            try self.validate(self.weeklyMaintenanceStartTime, name: "weeklyMaintenanceStartTime", parent: name, min: 7)
            try self.validate(self.weeklyMaintenanceStartTime, name: "weeklyMaintenanceStartTime", parent: name, pattern: "^[1-7]:([01]\\d|2[0-3]):?([0-5]\\d)$")
        }

        private enum CodingKeys: String, CodingKey {
            case autoImportPolicy = "AutoImportPolicy"
            case automaticBackupRetentionDays = "AutomaticBackupRetentionDays"
            case dailyAutomaticBackupStartTime = "DailyAutomaticBackupStartTime"
            case weeklyMaintenanceStartTime = "WeeklyMaintenanceStartTime"
        }
    }

    public struct UpdateFileSystemRequest: AWSEncodableShape {
        /// A string of up to 64 ASCII characters that Amazon FSx uses to ensure idempotent updates. This string is automatically filled on your behalf when you use the AWS Command Line Interface (AWS CLI) or an AWS SDK.
        public let clientRequestToken: String?
        /// Identifies the file system that you are updating.
        public let fileSystemId: String
        public let lustreConfiguration: UpdateFileSystemLustreConfiguration?
        /// Use this parameter to increase the storage capacity of an Amazon FSx file system. Specifies the storage capacity target value, GiB, to increase the storage capacity for the file system that you're updating. You cannot make a storage capacity increase request if there is an existing storage capacity increase request in progress. For Windows file systems, the storage capacity target value must be at least 10 percent (%) greater than the current storage capacity value. In order to increase storage capacity, the file system must have at least 16 MB/s of throughput capacity. For Lustre file systems, the storage capacity target value can be the following:   For SCRATCH_2 and PERSISTENT_1 SSD deployment types, valid values are in multiples of 2400 GiB. The value must be greater than the current storage capacity.   For PERSISTENT HDD file systems, valid values are multiples of 6000 GiB for 12 MB/s/TiB file systems and multiples of 1800 GiB for 40 MB/s/TiB file systems. The values must be greater than the current storage capacity.   For SCRATCH_1 file systems, you cannot increase the storage capacity.   For more information, see Managing storage capacity in the Amazon FSx for Windows File Server User Guide and Managing storage and throughput capacity in the Amazon FSx for Lustre User Guide.
        public let storageCapacity: Int?
        /// The configuration updates for an Amazon FSx for Windows File Server file system.
        public let windowsConfiguration: UpdateFileSystemWindowsConfiguration?

        public init(clientRequestToken: String? = UpdateFileSystemRequest.idempotencyToken(), fileSystemId: String, lustreConfiguration: UpdateFileSystemLustreConfiguration? = nil, storageCapacity: Int? = nil, windowsConfiguration: UpdateFileSystemWindowsConfiguration? = nil) {
            self.clientRequestToken = clientRequestToken
            self.fileSystemId = fileSystemId
            self.lustreConfiguration = lustreConfiguration
            self.storageCapacity = storageCapacity
            self.windowsConfiguration = windowsConfiguration
        }

        public func validate(name: String) throws {
            try self.validate(self.clientRequestToken, name: "clientRequestToken", parent: name, max: 63)
            try self.validate(self.clientRequestToken, name: "clientRequestToken", parent: name, min: 1)
            try self.validate(self.clientRequestToken, name: "clientRequestToken", parent: name, pattern: "[A-za-z0-9_.-]{0,63}$")
            try self.validate(self.fileSystemId, name: "fileSystemId", parent: name, max: 21)
            try self.validate(self.fileSystemId, name: "fileSystemId", parent: name, min: 11)
            try self.validate(self.fileSystemId, name: "fileSystemId", parent: name, pattern: "^(fs-[0-9a-f]{8,})$")
            try self.lustreConfiguration?.validate(name: "\(name).lustreConfiguration")
            try self.validate(self.storageCapacity, name: "storageCapacity", parent: name, max: 2_147_483_647)
            try self.validate(self.storageCapacity, name: "storageCapacity", parent: name, min: 0)
            try self.windowsConfiguration?.validate(name: "\(name).windowsConfiguration")
        }

        private enum CodingKeys: String, CodingKey {
            case clientRequestToken = "ClientRequestToken"
            case fileSystemId = "FileSystemId"
            case lustreConfiguration = "LustreConfiguration"
            case storageCapacity = "StorageCapacity"
            case windowsConfiguration = "WindowsConfiguration"
        }
    }

    public struct UpdateFileSystemResponse: AWSDecodableShape {
        /// A description of the file system that was updated.
        public let fileSystem: FileSystem?

        public init(fileSystem: FileSystem? = nil) {
            self.fileSystem = fileSystem
        }

        private enum CodingKeys: String, CodingKey {
            case fileSystem = "FileSystem"
        }
    }

    public struct UpdateFileSystemWindowsConfiguration: AWSEncodableShape {
        /// The number of days to retain automatic daily backups. Setting this to zero (0) disables automatic daily backups. You can retain automatic daily backups for a maximum of 90 days. For more information, see Working with Automatic Daily Backups.
        public let automaticBackupRetentionDays: Int?
        /// The preferred time to start the daily automatic backup, in the UTC time zone, for example, 02:00
        public let dailyAutomaticBackupStartTime: String?
        /// The configuration Amazon FSx uses to join the Windows File Server instance to the self-managed Microsoft AD directory. You cannot make a self-managed Microsoft AD update request if there is an existing self-managed Microsoft AD update request in progress.
        public let selfManagedActiveDirectoryConfiguration: SelfManagedActiveDirectoryConfigurationUpdates?
        /// Sets the target value for a file system's throughput capacity, in MB/s, that you are updating the file system to. Valid values are 8, 16, 32, 64, 128, 256, 512, 1024, 2048. You cannot make a throughput capacity update request if there is an existing throughput capacity update request in progress. For more information, see Managing Throughput Capacity.
        public let throughputCapacity: Int?
        /// The preferred start time to perform weekly maintenance, formatted d:HH:MM in the UTC time zone. Where d is the weekday number, from 1 through 7, with 1 = Monday and 7 = Sunday.
        public let weeklyMaintenanceStartTime: String?

        public init(automaticBackupRetentionDays: Int? = nil, dailyAutomaticBackupStartTime: String? = nil, selfManagedActiveDirectoryConfiguration: SelfManagedActiveDirectoryConfigurationUpdates? = nil, throughputCapacity: Int? = nil, weeklyMaintenanceStartTime: String? = nil) {
            self.automaticBackupRetentionDays = automaticBackupRetentionDays
            self.dailyAutomaticBackupStartTime = dailyAutomaticBackupStartTime
            self.selfManagedActiveDirectoryConfiguration = selfManagedActiveDirectoryConfiguration
            self.throughputCapacity = throughputCapacity
            self.weeklyMaintenanceStartTime = weeklyMaintenanceStartTime
        }

        public func validate(name: String) throws {
            try self.validate(self.automaticBackupRetentionDays, name: "automaticBackupRetentionDays", parent: name, max: 90)
            try self.validate(self.automaticBackupRetentionDays, name: "automaticBackupRetentionDays", parent: name, min: 0)
            try self.validate(self.dailyAutomaticBackupStartTime, name: "dailyAutomaticBackupStartTime", parent: name, max: 5)
            try self.validate(self.dailyAutomaticBackupStartTime, name: "dailyAutomaticBackupStartTime", parent: name, min: 5)
            try self.validate(self.dailyAutomaticBackupStartTime, name: "dailyAutomaticBackupStartTime", parent: name, pattern: "^([01]\\d|2[0-3]):?([0-5]\\d)$")
            try self.selfManagedActiveDirectoryConfiguration?.validate(name: "\(name).selfManagedActiveDirectoryConfiguration")
            try self.validate(self.throughputCapacity, name: "throughputCapacity", parent: name, max: 2048)
            try self.validate(self.throughputCapacity, name: "throughputCapacity", parent: name, min: 8)
            try self.validate(self.weeklyMaintenanceStartTime, name: "weeklyMaintenanceStartTime", parent: name, max: 7)
            try self.validate(self.weeklyMaintenanceStartTime, name: "weeklyMaintenanceStartTime", parent: name, min: 7)
            try self.validate(self.weeklyMaintenanceStartTime, name: "weeklyMaintenanceStartTime", parent: name, pattern: "^[1-7]:([01]\\d|2[0-3]):?([0-5]\\d)$")
        }

        private enum CodingKeys: String, CodingKey {
            case automaticBackupRetentionDays = "AutomaticBackupRetentionDays"
            case dailyAutomaticBackupStartTime = "DailyAutomaticBackupStartTime"
            case selfManagedActiveDirectoryConfiguration = "SelfManagedActiveDirectoryConfiguration"
            case throughputCapacity = "ThroughputCapacity"
            case weeklyMaintenanceStartTime = "WeeklyMaintenanceStartTime"
        }
    }

    public struct WindowsFileSystemConfiguration: AWSDecodableShape {
        /// The ID for an existing Microsoft Active Directory instance that the file system should join when it's created.
        public let activeDirectoryId: String?
        public let aliases: [Alias]?
        /// The number of days to retain automatic backups. Setting this to 0 disables automatic backups. You can retain automatic backups for a maximum of 90 days.
        public let automaticBackupRetentionDays: Int?
        /// A boolean flag indicating whether tags on the file system should be copied to backups. This value defaults to false. If it's set to true, all tags on the file system are copied to all automatic backups and any user-initiated backups where the user doesn't specify any tags. If this value is true, and you specify one or more tags, only the specified tags are copied to backups. If you specify one or more tags when creating a user-initiated backup, no tags are copied from the file system, regardless of this value.
        public let copyTagsToBackups: Bool?
        /// The preferred time to take daily automatic backups, in the UTC time zone.
        public let dailyAutomaticBackupStartTime: String?
        /// Specifies the file system deployment type, valid values are the following:    MULTI_AZ_1 - Specifies a high availability file system that is configured for Multi-AZ redundancy to tolerate temporary Availability Zone (AZ) unavailability, and supports SSD and HDD storage.    SINGLE_AZ_1 - (Default) Specifies a file system that is configured for single AZ redundancy, only supports SSD storage.    SINGLE_AZ_2 - Latest generation Single AZ file system. Specifies a file system that is configured for single AZ redundancy and supports SSD and HDD storage.   For more information, see Single-AZ and Multi-AZ File Systems.
        public let deploymentType: WindowsDeploymentType?
        /// The list of maintenance operations in progress for this file system.
        public let maintenanceOperationsInProgress: [FileSystemMaintenanceOperation]?
        /// For MULTI_AZ_1 deployment types, the IP address of the primary, or preferred, file server. Use this IP address when mounting the file system on Linux SMB clients or Windows SMB clients that are not joined to a Microsoft Active Directory. Applicable for all Windows file system deployment types. This IP address is temporarily unavailable when the file system is undergoing maintenance. For Linux and Windows SMB clients that are joined to an Active Directory, use the file system's DNSName instead. For more information on mapping and mounting file shares, see Accessing File Shares.
        public let preferredFileServerIp: String?
        /// For MULTI_AZ_1 deployment types, it specifies the ID of the subnet where the preferred file server is located. Must be one of the two subnet IDs specified in SubnetIds property. Amazon FSx serves traffic from this subnet except in the event of a failover to the secondary file server. For SINGLE_AZ_1 and SINGLE_AZ_2 deployment types, this value is the same as that for SubnetIDs. For more information, see Availability and Durability: Single-AZ and Multi-AZ File Systems
        public let preferredSubnetId: String?
        /// For MULTI_AZ_1 deployment types, use this endpoint when performing administrative tasks on the file system using Amazon FSx Remote PowerShell. For SINGLE_AZ_1 and SINGLE_AZ_2 deployment types, this is the DNS name of the file system. This endpoint is temporarily unavailable when the file system is undergoing maintenance.
        public let remoteAdministrationEndpoint: String?
        public let selfManagedActiveDirectoryConfiguration: SelfManagedActiveDirectoryAttributes?
        /// The throughput of an Amazon FSx file system, measured in megabytes per second.
        public let throughputCapacity: Int?
        /// The preferred start time to perform weekly maintenance, formatted d:HH:MM in the UTC time zone. d is the weekday number, from 1 through 7, beginning with Monday and ending with Sunday.
        public let weeklyMaintenanceStartTime: String?

        public init(activeDirectoryId: String? = nil, aliases: [Alias]? = nil, automaticBackupRetentionDays: Int? = nil, copyTagsToBackups: Bool? = nil, dailyAutomaticBackupStartTime: String? = nil, deploymentType: WindowsDeploymentType? = nil, maintenanceOperationsInProgress: [FileSystemMaintenanceOperation]? = nil, preferredFileServerIp: String? = nil, preferredSubnetId: String? = nil, remoteAdministrationEndpoint: String? = nil, selfManagedActiveDirectoryConfiguration: SelfManagedActiveDirectoryAttributes? = nil, throughputCapacity: Int? = nil, weeklyMaintenanceStartTime: String? = nil) {
            self.activeDirectoryId = activeDirectoryId
            self.aliases = aliases
            self.automaticBackupRetentionDays = automaticBackupRetentionDays
            self.copyTagsToBackups = copyTagsToBackups
            self.dailyAutomaticBackupStartTime = dailyAutomaticBackupStartTime
            self.deploymentType = deploymentType
            self.maintenanceOperationsInProgress = maintenanceOperationsInProgress
            self.preferredFileServerIp = preferredFileServerIp
            self.preferredSubnetId = preferredSubnetId
            self.remoteAdministrationEndpoint = remoteAdministrationEndpoint
            self.selfManagedActiveDirectoryConfiguration = selfManagedActiveDirectoryConfiguration
            self.throughputCapacity = throughputCapacity
            self.weeklyMaintenanceStartTime = weeklyMaintenanceStartTime
        }

        private enum CodingKeys: String, CodingKey {
            case activeDirectoryId = "ActiveDirectoryId"
            case aliases = "Aliases"
            case automaticBackupRetentionDays = "AutomaticBackupRetentionDays"
            case copyTagsToBackups = "CopyTagsToBackups"
            case dailyAutomaticBackupStartTime = "DailyAutomaticBackupStartTime"
            case deploymentType = "DeploymentType"
            case maintenanceOperationsInProgress = "MaintenanceOperationsInProgress"
            case preferredFileServerIp = "PreferredFileServerIp"
            case preferredSubnetId = "PreferredSubnetId"
            case remoteAdministrationEndpoint = "RemoteAdministrationEndpoint"
            case selfManagedActiveDirectoryConfiguration = "SelfManagedActiveDirectoryConfiguration"
            case throughputCapacity = "ThroughputCapacity"
            case weeklyMaintenanceStartTime = "WeeklyMaintenanceStartTime"
        }
    }
}
